Last modified: 2014-08-31 20:12:17 UTC
API results for transcodestatus and videoinfo don't include the file size of the transcoded assets -- though this can be estimated from the content duration (see bug 55941 for difficulties getting this) combined with the per-transcode bandwidth: https://commons.wikimedia.org/w/api.php?action=query&titles=File:Folgers.ogv&prop=transcodestatus&format=json https://commons.wikimedia.org/w/api.php?action=query&titles=File:Folgers.ogv&prop=videoinfo&viprop=derivatives&format=json For managing downloads or progress bars, it would be nice to have the byte count.
Hmm, final file size is not stored in db where all the other transcode info is pulled out of. bitrate is calculated exactly from file size though: $bitrate = round( intval( filesize( $this->getTargetEncodePath() ) / $file->getLength() ) * 8 );