MCPcopy Create free account
hub / github.com/IENT/YUView / calculateChromaSize

Function calculateChromaSize

YUViewLib/src/decoder/decoderVVDec.cpp:119–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

117}
118
119Size calculateChromaSize(Size lumaSize, vvdecColorFormat fmt)
120{
121 if (fmt == VVDEC_CF_YUV400_PLANAR)
122 return {};
123 if (fmt == VVDEC_CF_YUV420_PLANAR)
124 return {lumaSize.width / 2, lumaSize.height / 2};
125 if (fmt == VVDEC_CF_YUV422_PLANAR)
126 return {lumaSize.width / 2, lumaSize.height};
127 if (fmt == VVDEC_CF_YUV444_PLANAR)
128 return lumaSize;
129
130 return {};
131}
132
133} // namespace
134

Callers 2

copyImgToByteArrayMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected