-
Notifications
You must be signed in to change notification settings - Fork 11
Encoding Profiles
a-tze edited this page Nov 14, 2017
·
4 revisions
Encoding profiles in the tracker are XSLT Stylesheets that get a simple flat XML of all ticket properties as input. The output of the XSL transformation is called the "jobfile". The only limitation is that the output should be XML, beside that you can basically create anything you need for your worker scripts.
The example scripts use the XML format of the "CRS Executor" library. The format is documented there.
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="//properties">
<job>
<tasks>
<task type="encoding">
<option filetype="exe">ffmpeg</option>
<option>-i</option>
<option filetype="in">/opt/crs/fuse/<xsl:value-of select="//property[@name='Fahrplan.ID']" />/cut-complete.dv</option>
<option>-c:v</option>
<option>libx264</option>
<option>-c:a</option>
<option>aac</option>
<xsl:if test="string-length(//property[@name='Fahrplan.Title']) > 0">
<option>-metadata</option>
<option>title=</option>
<option><xsl:value-of select="//property[@name='Fahrplan.Title']" /></option>
</xsl:if>
<option>-f</option>
<option>mp4</option>
<option filetype="out"><xsl:value-of select="//property[@name='Processing.Path.Tmp']" />/<xsl:value-of select="//property[@name='Fahrplan.ID']" />-h264-hq.mp4</option>
</task>
<task type="postencoding">
</task>
</tasks>
</job>
</xsl:template>
</xsl:stylesheet>