"""
import base
-import api_exceptions
+import cis_exceptions
import subprocess
import re
import os
"vp8": "libvpx"
}
- def _transcode(self, container, a_codec=None, v_codec=None,
+ def _transcode(self, container, extension=None, a_codec=None, v_codec=None,
a_bitrate=None, a_samplingrate=None, a_channels=None,
v_bitrate=None, v_framerate=None, v_resolution=None, v_dar=None):
exit_code = p.wait()
if exit_code > 0:
- raise api_exceptions.TranscodingException( \
+ raise cis_exceptions.TranscodingException( \
'FFmpeg exited with code ' + str(exit_code) + '.')
log.close()
exit_code = p.wait()
if exit_code > 0:
- raise api_exceptions.ThumbExtractionException( \
+ raise cis_exceptions.ThumbExtractionException( \
'FFmpeg exited with code ' + str(exit_code) + '.')
# FFmpeg bug: when no key frame is found from seek_pos to the
# end of file an empty image file is created.
if os.path.getsize(output_file) == 0L:
os.unlink(output_file)
- raise api_exceptions.ThumbExtractionException( \
+ raise cis_exceptions.ThumbExtractionException( \
'FFmpeg created an empty file.')
def get_video_duration(self):
exit_code = p.wait()
if exit_code > 0:
- raise api_exceptions.AVInfoException( \
+ raise cis_exceptions.AVInfoException( \
'ffprobe exited with code ' + str(exit_code) + '.')