projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use a struct rather than a std::pair as the return type from ImageProxy::image.
[dcpomatic.git]
/
src
/
lib
/
ffmpeg_examiner.cc
diff --git
a/src/lib/ffmpeg_examiner.cc
b/src/lib/ffmpeg_examiner.cc
index 382b71b83442a36e2fe4910310131190fbfcb84f..3fb9a53e4618f49e6f4aedb82780e9f10de541b3 100644
(file)
--- a/
src/lib/ffmpeg_examiner.cc
+++ b/
src/lib/ffmpeg_examiner.cc
@@
-166,6
+166,13
@@
FFmpegExaminer::FFmpegExaminer (shared_ptr<const FFmpegContent> c, shared_ptr<Jo
DCPOMATIC_ASSERT (fabs (*_rotation - 90 * round (*_rotation / 90)) < 2);
}
DCPOMATIC_ASSERT (fabs (*_rotation - 90 * round (*_rotation / 90)) < 2);
}
+
+#ifdef DCPOMATIC_VARIANT_SWAROOP
+ AVDictionaryEntry* e = av_dict_get (_format_context->metadata, SWAROOP_ID_TAG, 0, 0);
+ if (e) {
+ _id = e->value;
+ }
+#endif
}
void
}
void
@@
-381,3
+388,16
@@
FFmpegExaminer::has_video () const
{
return static_cast<bool> (_video_stream);
}
{
return static_cast<bool> (_video_stream);
}
+
+VideoRange
+FFmpegExaminer::range () const
+{
+ switch (color_range()) {
+ case AVCOL_RANGE_MPEG:
+ case AVCOL_RANGE_UNSPECIFIED:
+ return VIDEO_RANGE_VIDEO;
+ case AVCOL_RANGE_JPEG:
+ default:
+ return VIDEO_RANGE_FULL;
+ }
+}