diff options
| author | John Hurst <jhurst@cinecert.com> | 2019-12-30 14:03:53 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-12-30 14:03:53 -0800 |
| commit | 9e269bd45830f54551722a65b0d7aa8f327e17dc (patch) | |
| tree | 6e03793692f45418ea89c55edcb95ce89d9aad5b /src/JP2K_Sequence_Parser.cpp | |
| parent | a67f55782d4758355190fe3f14ac6159b9d79e1e (diff) | |
| parent | 39d533e10e9f5248c557caa0777c8c10ed5d737c (diff) | |
Merge pull request #20 from cinecert/htj2c
WIP: add support for ST 422:2019
Diffstat (limited to 'src/JP2K_Sequence_Parser.cpp')
| -rwxr-xr-x | src/JP2K_Sequence_Parser.cpp | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/src/JP2K_Sequence_Parser.cpp b/src/JP2K_Sequence_Parser.cpp index a080440..c561033 100755 --- a/src/JP2K_Sequence_Parser.cpp +++ b/src/JP2K_Sequence_Parser.cpp @@ -251,6 +251,57 @@ operator==(const ASDCP::JP2K::CodingStyleDefault_t& lhs, const ASDCP::JP2K::Codi // bool +operator==(const ASDCP::JP2K::ExtendedCapabilities_t& lhs, const ASDCP::JP2K::ExtendedCapabilities_t& rhs) +{ + if (lhs.N != rhs.N) return false; + + if (lhs.N != JP2K::NoExtendedCapabilitiesSignaled) { + + if (lhs.Pcap != rhs.Pcap) return false; + + for (ui32_t i = 0; i < lhs.N; i++) + { + if (lhs.Ccap[i] != rhs.Ccap[i]) + return false; + } + + } + + return true; +} + +// +bool +operator==(const ASDCP::JP2K::CorrespondingProfile_t& lhs, const ASDCP::JP2K::CorrespondingProfile_t& rhs) +{ + if (lhs.N != rhs.N) return false; + + for (ui32_t i = 0; i < lhs.N; i++) + { + if (lhs.Pcpf[i] != rhs.Pcpf[i]) + return false; + } + + return true; +} + +// +bool +operator==(const ASDCP::JP2K::Profile_t& lhs, const ASDCP::JP2K::Profile_t& rhs) +{ + if (lhs.N != rhs.N) return false; + + for (ui32_t i = 0; i < lhs.N; i++) + { + if (lhs.Pprf[i] != rhs.Pprf[i]) + return false; + } + + return true; +} + +// +bool operator==(const ASDCP::JP2K::PictureDescriptor& lhs, const ASDCP::JP2K::PictureDescriptor& rhs) { if ( lhs.EditRate != rhs.EditRate ) return false; @@ -271,6 +322,9 @@ operator==(const ASDCP::JP2K::PictureDescriptor& lhs, const ASDCP::JP2K::Picture if ( lhs.Csize != rhs.Csize ) return false; if ( ! ( lhs.CodingStyleDefault == rhs.CodingStyleDefault ) ) return false; if ( ! ( lhs.QuantizationDefault == rhs.QuantizationDefault ) ) return false; + if (!(lhs.Profile == rhs.Profile)) return false; + if (!(lhs.CorrespondingProfile == rhs.CorrespondingProfile)) return false; + if (!(lhs.ExtendedCapabilities == rhs.ExtendedCapabilities)) return false; for ( ui32_t i = 0; i < JP2K::MaxComponents; i++ ) { |
