#include "dcp_decoder.h"
#include "image_content.h"
#include "image_decoder.h"
-#include "text_caption_file_content.h"
-#include "text_caption_file_decoder.h"
+#include "string_text_file_content.h"
+#include "string_text_file_decoder.h"
#include "dcp_subtitle_content.h"
#include "dcp_subtitle_decoder.h"
#include "video_mxf_content.h"
shared_ptr<const DCPContent> dc = dynamic_pointer_cast<const DCPContent> (content);
if (dc) {
- return shared_ptr<Decoder> (new DCPDecoder (dc, log, fast));
+ try {
+ return shared_ptr<Decoder> (new DCPDecoder (dc, log, fast));
+ } catch (KDMError& e) {
+ /* This will be found and reported to the user when the content is examined */
+ return shared_ptr<Decoder>();
+ }
}
shared_ptr<const ImageContent> ic = dynamic_pointer_cast<const ImageContent> (content);
return shared_ptr<Decoder> (new ImageDecoder (ic, log));
}
- shared_ptr<const TextCaptionFileContent> rc = dynamic_pointer_cast<const TextCaptionFileContent> (content);
+ shared_ptr<const StringTextFileContent> rc = dynamic_pointer_cast<const StringTextFileContent> (content);
if (rc) {
- return shared_ptr<Decoder> (new TextCaptionFileDecoder (rc, log));
+ return shared_ptr<Decoder> (new StringTextFileDecoder (rc, log));
}
shared_ptr<const DCPSubtitleContent> dsc = dynamic_pointer_cast<const DCPSubtitleContent> (content);