Showing posts with label En Masse. Show all posts
Showing posts with label En Masse. Show all posts

Monday, July 14, 2014

Test Encode: Vandelay

Vandelay (fictional name) is a TV sitcom that ran for nine years.  Since my USB-equipped DVD player only plays xvid + mp3 in avi videos (burned as data dvd), the files (in mkv format) will have to be converted.  The episodes are organized by season, as shown below:




Burning just 5 episodes on DVD5 is wasteful (as with Season 1) and is not an option.  It is worth noting that not all episodes are of equal duration and that some files are actually two episodes merged into one file.  In this case, Vandelay has a total of 180 episodes in 171 files.

Clicking "Select folder" ('step 2' of En Masse's main form) reveals that the Vandelay folder contains 171 files with a total duration of 67h 17m 19s.  Clicking 'Duration/x' reveals that opting for 6 discs would yield a video bitrate of 765 kbits/s, an audio bitrate of 128 kbits/s, and a maximum duration of 11h 25m 25s on DVD5.



After deciding to go with 6 discs, I then set out to re-organize the Vandelay folder.  I created six folders, and in conjunction with 'GetTotalDuration.exe', placed the maximum amount of files in each folder that would yield a total duration not exceeding 11h 25m 25s.



As shown above, episodes 1-31 (Disc 1) yields a total duration of 11h 20m 30s.

I then created a new preset with bitrate settings as suggested by 'Duration/x' (765 + 128 kbits/s), and went through steps 1-4 (select preset, select folder, generate, convert).

After ffmpeg processed the files for 40h 30m 24s (real files were used, btw), I ended up with the following:




Download VidProkEnMasse:
http://vidprokenmasse.blogspot.com/2014/07/vidprokenmasse.html


VidProk: Preview ffmpeg filters

VidProk lets you preview ffmpeg filters (no more test encodes, yey!).  Additionally, it includes a VF cheat sheet which lets you conveniently copy/paste filters.



Some of the video filters include:  Add noise, color curves, deinterlace, denoise (hqdn3d), deshake, draw box, draw grid, fade in, flip horizontal, flip vertical, gamma, geq - emboss, grayscale, histogram, hue and saturation, mplayer: gamma, brightness, contrast (experimental), negate, pp - deblocking, deringing, auto brightness & contrast, sepia, smartblur, unsharp, vignette, and YUV420P.

The VF cheat sheet is by no means a substitute for ffmpeg's documentation --- so, if the default values do not satisfy you, read the ffmpeg manual.

Here are some screen shots...

'play both (horizontal)':
filters used: gamma, curves, saturation, unsharp, denoise, deblock, yuv420p






'play both (vertical)':



And finally, 'play both @ pos 0x0':  Both source and processed windows are placed on the top left corner (one window obscures the other).  Clicking 'toggle' alternates between the source and processed windows.  This lets you easily see the differences, especially small differences, between the processed and the source windows.

 I know that ffmpeg is a no-joy in the instant gratification department, but I hope you'll like using this tool.

Youtube demo:
http://youtu.be/zgXiGfZlTVo

VidProk is included in 'VidProkEnMasse', it is absolutely free, and you can download it here:
http://vidprokenmasse.blogspot.com/2014/07/vidprokenmasse.html


VidProkEnMasse

VidProkEnMasse is an all-ffmpeg solution for your daily video encoding needs.  The name is derived from its two major apps in the collection.  "VidProk" processes videos 'piece-meal' while "En Masse" batch processes videos (last tested on 1849 files).

Apart from their intended use, VidProk and En Masse are also excellent learning tools for new ffmpeg users as both apps readily reveal their ffmpeg 'recipes'.  While the GUI provides convenience for experienced ffmpeg users, you don't have to be an ffmpeg guru to use VidProkEnMasse.  It does not include a large collection of device-specific presets, but it fairly outlines some of ffmpeg's vast capabilities.  You can consider the example presets as a sort of walk-through.

VidProkEnMasse is a home-brew solution created by a frustrated end-user for other end-users.  It does not write to the registry, does not automatically 'phone home' for updates, does not nag, does not coerce your browser to a new home page/search engine or to install a new toolbar, and does not require you to join a cult.  VidProkEnMasse is absolutely free, though small donations are very much welcome.  Email me: chiqboy<[at]>gmail<[dot]>com

En Masse features:
1.  Easy operation:  Select preset, select folder, generate batch file, convert.
2.  The usual features:  Burn-in *.srt (SubRip) subtitle files, single-/two-pass encoding, crf-/quantizer-/bitrate-based encoding, generate video statistics logs, shutdown after encoding, etc.
3.  Logged encodes:  Elapsed time, render speed, rendered file size, possible failed encode, etc.
4.  Preset Manager - Bitrate-based encodes: Integrated qf calculator.  Max duration on DVD-5/-9.  Resize all videos to one width or depending on aspect ratio, or no resize at all (square pixel/anamorphic).
5.  Queue Stats readily displays total number of files/size, total duration, and estimated total output size (if available).
6.  Integrated bitrate calculator (Duration/x).  Suggests video bitrate based on total video duration (as on Queue Stats) and the number of discs you specify.
7.  Text expansion support (%variables%).

VidProk features:
1.  Easy operation:  Drag/drop video, select preset, add video filters, tweak, preview, encode.
2.  The usual features:  Burn-in *.srt (SubRip) subtitle files, single-/two-pass encoding, crf-/quantizer-/bitrate-based encoding, extract frames to jpg files, extract screen shots, extract embedded subtitles to srt, extract audio to wav, change container or discard/copy stream, generate video statistics logs, crop/scale/distort frames, select/tweak/preview video filters, etc.
3.  Logged encodes:  Elapsed time, render speed, rendered file size, possible failed encode, etc.
4.  Text expansion support (%variables%).
5.  Unique feature:  LAP (low, average, peak).  Answers the question: 'What's the peak video birate like if I were to encode with XYZ settings?'.

Some of the other tools included:

GetTotalDuration.exe:  Computes total and average duration of dragged/dropped video files.

JoinAVstreams.exe:  Stream copy/mux.  May fix generally faulty videos or some rogue mkv files (variable frame rate with missing frame count).

AnalyzeVstatsLogFile.exe:  Similar to "LAP".  Reads ffmpeg-generated video statistics logs and retrieves low/average/peak q, low/average/peak bitrate, etc.  Ever wondered what the bitrate is like for T.V. noise?


En Masse demo:
https://www.youtube.com/watch?v=6pSH8lQZpRQ

Download VidProkEnMasse:

Click Here

Update: VidProkEnMasse_20170116
1. Modified scale routine: If Width combo boxes are left blank, no scale filter will be applied. I was compelled to implement this when I processed videos from a smart phone (annoying "portrait" videos).

2. Added "SRTFix.exe" (GUI) and "SRTFixCLI.exe" (command line). Both attempt to fix subtitles (*.srt) with long lines that go right off the screen. Limits subtitles to two rows when max characters is exceeded.

3. Added "GaugeVideoGenerator.exe". Default settings attempt to replicate the visual content (bitrate-wise) of "Transformers - Age of Extinction (2014)"... shortened to 100 seconds. Lets the user guesstimate output file size of crf-/quantizer-based encodes. Said movie, AFAIK, has the highest bitrate for a feature film. May answer the silly question: "What is the equivalent bitrate of crf 23?"

4. Added %presetdetails% to text expansion. Useful when used on metadata comment.

%presetdetails% expands to:
PresetName: V/A codec: vc+ac. V/A bitrate: vb+ab. fps: x. Widths: a, b, c, d. PIFA: xyz. VFA1: xyz. VFA2: xyz. PvfFFA: xyz.

5. Added %loud% to text expansion which makes audio output significantly louder

%loud% expands to:
-af "aformat=channel_layouts=stereo, compand=0 0:1 1:-72/-72 -48/-6 -3/-3 24/-3:0.01:0:-96:0"

6. Updated to "ffmpeg-20160116-git-d7c75a5-win32-static" which works on my OS (Windows XP 32-bit). Please feel free to replace with the latest ffmpeg Zeranoe static build if desired/required.

7. Unfortunately, VidProkEnMasse, being written in AutoIt, still suffers false positives from lazy AV software companies :\


Update:  VidProkEnMasse_20140714
1. Renamed app to 'VidProkEnMasse'.
2. Added text expansion feature (%variables%).
3. Added 'AnalyzeVstatsLogFile.exe' which retrieves info (like peak q, peak bitrate, etc) from vstats log files.
4. VidProk: Added 'LAP' (Low, Average, Peak) which performs video statistics gathering and retrieves info similar to 'AnalyzeVstatsLogFile.exe'.
5. Added 'Longest.Line.In.Srt_[DROP.SRT.FILE.HERE].exe'.
6. Numerous tweaks.
7. Updated to ffmpeg-20140712-git-ca671be-win32-static.
8. Moved site to http://vidprokenmasse.blogspot.com/2014/07/vidprokenmasse.html

Update:  EnMasse_20140528
1. Dropped MediaInfo in favor of ffprobe (En Masse is now an ALL-ffmpeg solution).
2. En Masse: Burn-in subtitles (batch mode).
3. New policy: Maintain anamorphic dimensions if not resized.
4. Two-pass encoding.
5. VidProk encoding is now logged.
6. Numerous tweaks.
7. Updated to ffmpeg-20140502-git-0f9f24c-win32-static.