= Custom Preview Commands =

Gaupol supports preview of subtitles with an arbitrary external video player. Video players are launched to start playing right before the selected subtitle. The subtitle file does not need to be saved -- if unsaved, Gaupol will save it to a temporary file and tell the video player to use that file.

Commands for two multiplatform video players -- [[http://www.mplayerhq.hu/|MPlayer]] and [[http://www.videolan.org/vlc/|VLC]] -- are predefined. For other video players you'll want to use a custom command. The following fields can be used in the command.

 * `$MILLISECONDS` (since Gaupol 0.17)

 * `$SECONDS`

 * `$SUBFILE`

 * `$VIDEOFILE`

`$SUBFILE` and `$VIDEOFILE` do not need to be quoted in the command, they will be automatically quoted in a suitable manner. If your favorite video player takes the start time argument in different units, file a bug report to have support for that unit added. Below are commands for some common video players that can be used with Gaupol.

== Media Player Classic ==

Gaupol does not include a preset command for Media Player Classic, since the path to the executable varies greatly. There are at least two versions of the player: [[http://sourceforge.net/projects/guliverkli/|Media Player Classic]] and [[http://mpc-hc.sourceforge.net/|Media Player Classic Home Cinema]] and either of those is included in many codec packs. For example, with Media Player Classic Home Cinema included in [[http://www.cccp-project.net/|CCCP (Combined Community Codec Pack)]] use the following command.

{{{
"C:\Program Files\Combined Community Codec Pack\MPC\mpc-hc.exe" $VIDEOFILE /start $MILLISECONDS /sub $SUBFILE
}}}

With other versions of the player, the location and name of the executable can be different, but the arguments should be the same. Most users will probably want to uncheck the "Always use UTF-8 character encoding" option, since Media Player Classic has no option to specify subtitle file encoding.
