PowerShell Photo Slideshow

GitHub Source

Project Description

Photo slideshow implemented in PowerShell -> Windows Forms

Simply target a (nested) folder of images. Local or LAN UNC path supported.  
 

Features:

  • task tray icon to start slideshow on demand...
  • otherwise kicks off after user defined idle timeout (honors running video)
  • good randomization - one soon realizes pleasantly random photos are the key want of a photo slideshow ... fortunately PowerShell has a readily available random commandlet that seems to do quite well
    • persists "lastShown" for each subfolder and avoids re-showing within XX days (currently 1 month)
  • image fade-in and slide for ambience
  • several hotkeys functional:
    • open current image folder
    • copy current image to _My Photos_
    • rotate current image (and save) - *generally honors EXIF rotation metadata where present, this option allows for manual correction where EXIF is missing*
    • reverse to previously shown photo (left cursor)
    • pause/play (space)
    • hotkey legend pops up on any other keypress
  • screen click functions:
    • double click in center hides slideshow
    • single click in center pauses slideshow
    • click arrows on far left and right for prev/next image
  • skips .hidden folders
  • plays videos via VLC
  • open to modification - it's just PowerShell 🙂 no compiling tools required

Install - basically just launch the ps1... here's some tips:

  1. only the ps1 and ico files are needed, download them to a folder
  2. ensure VLC.exe is in your path
  3. (see screenshot below) create a shortcut to the ps1 and tweak the target to include powershell before the ps1 filename...
  4. example full shorcut command line: C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -WindowStyle Hidden \\beejquad\Dev\_PersonalProjects\PoShSlideshow\PoShSlideshow.ps1 -photoPath \\beejquad\photos -idleTimeout 2
  5. select Run: Minimized to make script launch more polished
  6. add -WindowStyle Hidden after powershell.exe on target command line for further polish
  7. then hit the Advanced button and select Run as administrator - this is only required for the powercfg /requests used to identify running video and avoid starting slideshow after user input idle timeout (wouldn't mind hearing a slicker approach???)
  8. script parameters:
    • add -photoPath {path\to\your\images} to the end of the shortcut path - UNC shared folder fair game, write permissions required to persist folder cache flat file
    • add -idleTimeout 2 to the end of the shortcut path - units are in minutes
  9. Copy this shortcut to shell:startup in Windows FileExplorer to automatically launch this script when you login to your desktop

Wishlist

  1. [done] show videos as well - thinking VLC convenient
  2. Right mouse to show commands menu same as keyboard
  3. Implement a Hide button akin to the forward back buttons
  4. Email current photo - on screen keyboard? fire gmail to get contacts
  5. blog request: Automatically update folder cache upon new items... to be clear, current approach automatically recognizes new files in existing folders since it only caches the list of folders from which it randomly grabs the next image. Thoughts - Seems pretty straightforward to throw in PowerShell FileWatcher configured to call the existing updateFolderCache function.

Understanding Exposure

This is a great book by a Mr. Bryan Peterson

Make sure you get the latest edition (currently Aug.2010).

Bryan has a an easy going writing style packed with tons of real examples.

It’s not a very long book (~175 pages) and there are lots of great example photos filling up nearly every page.

It is highly rated on Amazon… only $20 with shipping.

Basic takeaways for my own future reference:

  • Bryan uses the term “Exposure Triangle” to relate the three interrelated fundamentals of capturing ideal exposure: F-stop (aperture size), Shutter Speed and ISO.
  • Photography of course has a lot to do with *light* … how much light we have to work with and how much we want to let into the camera.
  • ISO
    • Undoubtedly the toughest one to grasp at the pure physics level. I appreciate how Bryan uses the simple metaphor of “worker bees” here.
    • The higher the ISO, the more worker bees you have on your electronic photo sensor gathering the light particles. There is of course a trade-off and I think we’ve all observed the grainy result of too much ISO.
    • It’s great to read the specific values & tips Bryan recommends throughout the book… e.g. setting your ISO higher than 200 starts to lose contrast and color saturation.
  • f/stop (aperture size)
    • aperture is literally the size of the opening allowing light to enter the camera… Yet just controlling the amount of light is not really the most useful aspect of f-stop…
    • More importantly f-stop is what determines the “depth of field” in a photograph.
    • F/4.5 is a very “average” middle point to begin with.
    • The *higher* the F/# the *smaller* the aperture (light opening) (because the number is on the bottom of a division)
    • Smaller apertures wind up pulling in a greater “depth of field” which just means more of the background is sharper.
    • Wider apertures (*smaller* f/#’s, i.e *divided* by a smaller number = bigger) give that fuzzy background effect (bokeh)… typically when you want to draw the most attention to a specific subject vs a complex background.
  • Shutter Speed
    • this is the most intuitively obvious one in my mind… it primarily determines whether you capture motion or not… a quick shutter “stops action”… a slow shutter gives that more blurry look to moving objects like water.

We then balance all three of those in our “Exposure Triangle”…

For one example, starting with the desire to have full focus on a long view (e.g. big field of flowers), we select a high f/stop. If it’s a bright easy light day, we can leave our ISO low … lastly we move the shutter speed up or down until our camera’s light meter falls on ZERO.

I had never been clued in on that fundamental part about adjusting one or the other (aperture or shutter) in order to *move*the*light*meter* bar back to center zero.  One typically does this looking through the viewfinder at the little gauge of vertical bars with 0 in the middle.

This was a pretty big revelation for me.  Maybe I’m particularly clueless 🙂 and it’s considered so obvious that it’s not worth mentioning; but I also wonder how many people carry around multiple hundred dollar cameras without knowing this.

For an alternative example, if we want to capture that “blurry water” effect on a stream or a waterfall, we’ll start with a longer shutter to (e.g. 1/8 sec or even 1 full sec) and then move the f/stop to get the light meter to 0… the f/stop will be high in this case (perhaps even f/32) because a long shutter is a long exposure to light and therefore a correspondingly small opening is necessary to counteract that light washout (i.e. overexposure).

Understanding Exposure, 3rd Edition - Bryan Peterson (2010.08) -cover image
ISBN-10: 0817439390
ISBN-13: 978-0817439392

[SOLVED!] Photoshop CS5 – Detected Video Card: Blank

TL;DR

Just go into Help > System Info before you do anything else, that’s it.

TS;WM

Unbelievable but this works 100% of the time on my current rig running Photoshop CS5 on Windows 7 with an ATI x1300 Pro graphics card (yeah yeah it’s far from a graphics superstar but honestly it does everything I need, including Photoshop 3D mode just fine thank you 🙂

Anyway, the area under Edit > Preferences > Performance > GPU Settings > Detected Video Card would always come up blank. This was absolutely driving me nuts because I want all the 3D mode stuff that only comes when Photoshop is happy with your OpenGL bits.

There are several forum posts about Photoshop being sensitive to what your video card spits out when PS does an OpenGL “capability scan”. Sure is cool to have such an easy fix… found it totally by chance. Obviously it would be nice if Adobe could find it in their hearts to run the video detect code through the System Info code but I’m sure they’ve got a ton of bigger fish to fry.

[Update: 01 Feb 2011] Photoshop CS5 on the Mac side has no such issues recognizing this card.

[Update: 04 May 2011] Photoshop CS5 64bit on Win7 seems to find the card straight away, nice. **Note: I had to install the ATI Catalyst drivers, the default Windows WDDM drivers didn’t provide the right kind of OpenGL support… for this old card Catalyst v10.2 seems to be the “legacy” cutoff point.

More keywords for Google to bring home other wayward souls: Photoshop, CS5, No Detected Video Card, Enable OpenGL Drawing, Enable Graphics Hardware Acceleration is unavailable, GPU Settings

Before After
image image