[Octolapse] Snapshot Directory Name

Looking for some help with the way snapshots are saved.

I am turning off the removal of the snapshots in Octolapse in the Snapshot settings so that I can download the images after and play with them in some video editing software.

It is working, but the location where they are being saved to is strange to me and I see no way of setting it with the Octolapse GUI. Inside of my .octoprint/data/octolapse/snapshots/ I end up having a directory named something like "79e1027e-5fba-4deb-89c0-a337f53549ec" with another directory inside it named "556c8835-e13a-49a7-a76f-8507f86bcbff". Then the snapshot files are in there named perfectly.

Is there a way to change this behavior? Is if there's a way to make the directory naming follow the gcode filename instead of what is happening.

I'm using Octoprint 1.3.10 with Octopi v 0.16.0, running on Raspberry Pi 3 Model B Plus Rev 1.3

Thanks.

That directory structure was used for convenience to ensure that I never overwrite any timelapse images accidentally. The first strange string (79e1027e-5fba-4deb-89c0-a337f53549ec in your case) is a GUID (globally unique identifier) that represents the current print. I assign one at the beginning of the print. The second one identifies the camera used, since users can create and use as many cameras as they like.

I'll think about ways of making the process of grabbing new images easier (maybe from a zip downlaod?), but for now you could use a Before Render Script script (available within the camera settings) to copy your images to any directory you like. It takes a little doing, and you might want to skim the wiki guide for creating custom DSLR camera scripts for pointers, though most of it doesn't apply to your case. I'll think about adding a guide for copying images before rendering.

Thank you. I had a feeling it was gonna take a script.
A zip download would definitely be useful. Personally though I don't mind transferring the whole directory over to my local HD.

Wish I could configure my camera to run an external script, but alas it is too old. Need an upgrade desperately to take better photos.

1 Like

The script would be pretty simple depending on how you are transferring the files. Maybe I'll add another script section specifically for this purpose in the future, and provide some more useful arguments. I still haven't gotten around to creating a file browser either, which I had wanted for the initial release over a year ago :slight_smile:

Your best bet to get better photos on a webcam is to increase your lighting and decrease your exposure. You'll get better details and less blur. Check out this guide if you haven't seen it already. Mileage may vary, but spending an hour adjusting your lighting (search for three point lighting on google if you don't know what that is) and your camera settings. Unfortunately the camera settings are kind of clunky on the current release of Octolapse. It will improve dramatically in the next release.

That new UI looks great!

I tried this...
mkdir -p "${SNAPSHOT_DIRECTORY}"/"${TIMELAPSE_OUTPUT_FILENAME}"
but it didn't work. I get an error that the process does not exist.

I put my file into the scripts folders and put /home/pi/scripts/mvsnaps.sh into the After Render Script section of my camera. I also made sure to run the chmod +x on the file as well.

Maybe my syntax is wrong as I'm pretty new to this OS. Any help is greatly appreciated.

Also, I'm wondering if this command might work...
Basically trying to rename the directory to one with the filename from the gcode.
mv "${SNAPSHOT_FULLPATH_TEMPLATE}" ${SNAPSHOT_DIRECTORY}"/"${TIMELAPSE_OUTPUT_FILENAME}"

I'm going to be working on the camera scripts soon, and will see if I can come up with a script for you. Eventually I want to develop a library of scripts from which users can choose, including a copy script.

Any update on this?

Thank you.

No, I have been struggling to get v0.4 out for like 9 months, lol! It's winding down now since I've gotten the first devel/rc out. Once I release 0.4 on the master branch (you'll see an update in Octolapse) message me again and I'll work on this for you!

Sorry I sort of lost track of this. I think the features in the new version will be worth it in the end, and will hopefully offset some of the delay :slight_smile: