Wednesday, March 20, 2013

How to use 'Automator' actions


MKV2M4V (1.2.2 or later) includes some 'Automator' actions. If it installed this app and run 'Automator', it can see MKV2M4V-related actions.

(1.3.0 or later)
• ‘Add and Convert’

(1.2.2 or 1.2.3)
• 'Add Files to List'
• 'Add List to Queue'
• 'Change Options'
• 'Start to Convert'

It can see more informations about each actions at the action's description of 'Automator'.


And because ‘Automator’ doesn’t support ‘Sandbox’, there are some restrictions about actions by it. 

(1.3.0 or later)
As for ‘Add and Convert’ action, video and subtitle files (folders) should be in (be) the following folders or its subfolders; Folders that once opened while the app is running, MKV2M4V’s the place to save.

(1.2.2 or 1.2.3)
These 'Automator' actions work with the video files that are in the following folders or its subfolders; 'Downloads', 'Movies', MKV2M4V's the place to save.


The following screenshot shows the example for using actions in 'workflow' type.

(1.3.0 or later)
• ‘Ask for Finder Items’ > ’Add and Convert’ > ’Reveal Finder Items’


(1.2.2 or 1.2.3)
• 'Ask for Finder Items' > 'Add Files to List' > 'Change Options' > 'Add List to Queue' > 'Start to Convert' > 'Reveal Finder Items'

※ In this example, 'Change Options' and 'Add List to Queue' actions can be omitted.






Tuesday, March 19, 2013

Closed Captions, Hard-Subtitles/Soft-Subtitles


There are two types in embedded subtitles: Hard-subs and Soft-subs.

• Hard-subs
  - It is merged to video frames.
  - It can NOT be removed and modified, hided.
  - It requires video track re-encoding. (So it takes very LONG times to add subtitles.)
  - Decoding video frame > Creating subtitle image > Merge both into one frame > Encoding video frame.

• Soft-subs
  - It is inserted to a separated track.
  - It can be removed by removing the subtitle track and be hided.
  - It doesn't require video track re-encoding. (So it takes very SHORT times to add subtitles. It's very efficient.)
  - Just add subtitle track into the container (M4V, MP4 or MOV).

'Closed Captions (CC)' is 'Soft-subs'. And there are some restrictions by OS X / iOS.
  - Font type and size used in 'Closed Captions' are determined by OS X / iOS.
  - Supported tags and subtitles position are limited. 
  - So it can't be displayed as the MKV's embedded subtitles (SSA, ASS with embedded 'ttf' fonts).

※ It can now change the style of 'Closed Captions' on OS X 10.9 or later, iOS 7.0 or later, Apple TV 6.0 or later. But if changed style is applied, color tags in CC are ignored at Apple TV.
• OS X: 'System Preferences' - Accessibility - Captions - Click '+' button
 iOS (Apple TV): 'Settings' - General - Accessibility - Subtitles & Captioning - Style - Create New Style (Edit Styles)

So, MKV2M4V doesn't support 'Hard-subs' way because of these reasons.


MKV2M4V adds 'CC' into the target file (M4V, MP4 or MOV) using SRT subtitle files without video track re-encoding (So it's very fast). 

If it chose the 'ssa', 'ass' or 'subrip' subtitle track, first, it is converted to SRT subtitle file without embedded 'ttf' fonts because of the reasons described above. And then if another srt files don't exist, this SRT subtitle file will be used in adding 'Closed Caption'.



The following is the explanation on how to add 'Closed Caption' and turn on it.

First, there are some restrictions by 'Sandbox'. Sandboxed-app can't open files without the user's explicit access. So, if it opens not folders but video files, srt files should be in the following folders or its subfolders to use them automatically. If not, it should open it manually; Folders that once opened while the app is running, MKV2M4V’s the place to save. 

Next files are in '/Users/bohoonkim/Movies/test' folder. And in this case, 'video_file_name.srt' and 'video_file_name*.srt' files can be used for adding 'CC' when it converts 'Sample.mkv' file.


But if it explicitly opens only 'Sample.mkv' file, it can't access these srt files.


Thus it should explicitly open three files or '/Users/bohoonkim/Movies/test' folder to access them.


'Sample.mkv' and two srt files were opened. (These SRT files' text encoding is UTF-16. Of course it also supports UTF-8.)


If 'CC' was successfully added, 'Caption.' will be displayed as the following after conversion.


And then, this converted file, 'Sample.m4v' was played on QuickTime Player and turn on 'CC' by using 'balloon' button in the control bar. (on OS X 10.10.x)


And screenshot with another converted file on iTunes. (on OS X 10.10.x)