Page 2 of 2

Re: Change strange snapshot filename to useful/meaningful name

Posted: 09 Jul 2007 12:42
by jbutler
Cool.

Thank you for all the work you do.

--Jeremy

Re: Change strange snapshot filename to useful/meaningful name

Posted: 20 Sep 2007 03:32
by jbutler
Just ran into a problem with special characters in the Mac OSX Intel version of VLC -- particularly, trunk-intel-20070818-0129.dmg (8/18 is the latest Mac build I can get to run; I haven't found any after that that will work on my system).

When I use the $T option, the part of the filename with time code in it has slashes where, in the Windows version, there are underscores. So, my previous example would look like this:

Ep01_00/00/50_000001.png

You can see the trouble this would cause on a Mac machine, or if I were to upload this file to a Linux box.

Mac does not permit colons in file names (much like Windows). Is Mac converting colons to slashes somehow? Or is VLC doing this?

Thanks for any assistance.

Re: Change strange snapshot filename to useful/meaningful name

Posted: 11 Jul 2009 01:55
by jbutler
Version 1.0.0 seems to have broken the timecode variable: $T.

In the Mac OS X version, it tries to save the timecode with colons in it, which the OS converts to slashes in the file name. And in the Windows version, it just wigs out when you try to use $T. That is, it does not make a snapshot at all.

So, in Mac, if you set the prefix to, say,

Code: Select all

AMovieqq$Tqq
, with sequential numbers, it tries to create

AMovieqq00:03:01qq00003.jpg

but it winds up like

AMovieqq00/03/01qq00003.jpg

As I recall, this was pretty easy to fix previously.

Thanks!

Re: Change strange snapshot filename to useful/meaningful name

Posted: 11 Jul 2009 16:27
by VLC_help

Re: Change strange snapshot filename to useful/meaningful name

Posted: 19 Jul 2009 11:23
by cypressor
I can confirm that taking snapshots on Windows XP using $T in snapshot prefix is no longer possible since version 1.0.0. The reported bug has been closed with "worksforme" though. Could you please reopen it? Thanks.

Re: Change strange snapshot filename to useful/meaningful name

Posted: 19 Jul 2009 18:12
by VLC_help
Reopened with log message.

Re: Change strange snapshot filename to useful/meaningful name

Posted: 19 Jul 2009 19:13
by jbutler
And just to reconfirm the situation on Mac OS X:

Something has changed in the captures from version 9.9 to 1.0.0. See the image below, containing a screenshot from Finder that shows three version 1.0.0 snapshots on top (e.g., Movieqq00/14/26qq00003.png) with slashes in the file names and three version 9.9 snapshots, from Oceans Eleven, with underscores in the file names.

When VLC displays the name of the snapshot that it is capturing, there are colons in the names, but OS X somehow converts them to slashes, which can be confusing. I'd lobby for only using underscores as they are acceptable in Linux, Windows and Mac OS X.

Thanks for checking on this.

Image

Re: Change strange snapshot filename to useful/meaningful name

Posted: 09 Aug 2009 21:42
by jbutler
When I try to go to

https://trac.videolan.org/vlc/ticket/2955

I get a 404 error. Is the ticket dead, or is the site having a problem?

Does anyone know if the file name issue was resolved in 1.01? I don't see any mention of it in the changelog:

http://wiki.videolan.org/Changelog/1.0.1

Thanks.

Re: Change strange snapshot filename to useful/meaningful name

Posted: 10 Aug 2009 00:58
by nikola23
When I try to go to

https://trac.videolan.org/vlc/ticket/2955

I get a 404 error. Is the ticket dead, or is the site having a problem?

Does anyone know if the file name issue was resolved in 1.01? I don't see any mention of it in the changelog:

http://wiki.videolan.org/Changelog/1.0.1

Thanks.
Trac is down right now, and not everything is in the change log, only major changes.

Re: Change strange snapshot filename to useful/meaningful name

Posted: 10 Aug 2009 15:50
by VLC_help
AFAIK it hasn't been fixed. (at least nobody has closed the ticket or mentioned this on mailing list)

Re: Change strange snapshot filename to useful/meaningful na

Posted: 16 Jan 2011 22:17
by Ashantyk
you can customize your snapshot output name by editing the prefix field in Settings - > Video (Simple mode)

for example for prefix "$N" (dollar simbol and a letter), and checking 'sequential naming'
your snapshop filename will be <filename>.<video_extension><number>.<png/jpg>, where <number> is a 5 digit number self-incrementig if already exists :)

hope this helps

i tried this on VLC 1.1.5 using the variables from here: http://wiki.videolan.org/Documentation: ... mat_String

Re: Change strange snapshot filename to useful/meaningful na

Posted: 19 Oct 2012 15:10
by Mc_Dio
would be nice to just have the Filename in the name of the Snapshot - is this possible today ?

Re: Change strange snapshot filename to useful/meaningful na

Posted: 19 Oct 2012 15:17
by Mc_Dio
Well look what i found:

How does it work? $N is a variable of VLC, and it stands for media name. In fact, there are more variables that you can try other than $N, like:

$a : artist
$b : album
$g : genre
$t : title
$u : url
$A : date
$B : audio bitrate (in kb/s)
$C : chapter (as in DVD chapter number)
$D : duration
$F : full name with path
$I : title (as in DVD title number)
$L : time left
$N : name (media name as seen in the VLC playlist)
$O : audio language
$P : position (in %)
$R : rate
$S : audio sample rate (in kHz)
$T : time code of the video
$U : publisher

http://www.o-learn.com/content/vlc-medi ... a-filename

Re: Change strange snapshot filename to useful/meaningful name

Posted: 10 Sep 2016 19:40
by VLmurphy
Unfortunately, the snapshot file naming is still messy in VLC 2.4.4 as of today.
  1. There's still no variable simply returning the actual file name, no matter what.
  2. $N and $t (apparently) provide exactly the same, often nonsensical media name.
  3. Unticking "sequential numbering" returns completely random time stamps like "8965-03-14-22h57m08s691",
    but not the current date and time stamp as documented in the VideoLAN Wiki (I'm using Win7 Pro SP1 btw),
    albeit %Y, %m, %d, %H, %M, %S are returning the correct values.
  4. $T returns a false string format (HH_MM_SS instead of HH-MM-SS). *
  5. Alas, the most comprehensible request suggested by the OP ten(!) years ago is still not implemented: frame numbers. **
    That would solve any problems regarding sensible and unique file names; "unique" as in "unique names for identical images".
* I understand this is due to ":" being a forbidden character in NTFS filenames, but you could use "." instead. However, "-" works on all platforms and is the most current string format for date and time strings ... as also used in automated time stamps already, see above. The correct format should read YYYY-mm-dd_HH-MM-SS instead of YYYY-mm-dd-HH-MM-SS though, separating date and time with an underscore for better readability.


** Since $f is unhappily occupied already by something not viable for file names (neither file name nor frame number but total decoded frame count, duh) I'd propose using $m and $M, as in fraMe:

$m = relative frame number within the same time code second (00-99)
$M = absolute frame number (00000000-35999999 = frame number of time code 99:59:59:99)

You could also use $k and $K as a reference to Keykode ^^


So then with <filename>_$T.$m you would get a perfect file name for snapshots, like Friends.S01E08.avi_00-23-57.19.png ...
(although I personally would prefer to omit the file name extension, but for the sake of uniqueness it should probably be left in.)