MCPcopy Create free account
hub / github.com/ImpulseAdventure/JPEGsnoop / DecodeApp2IccProfile

Method DecodeApp2IccProfile

JfifDecode.cpp:3209–3233  ·  view source on GitHub ↗

Parser for APP2 ICC profile marker

Source from the content-addressed store, hash-verified

3207
3208// Parser for APP2 ICC profile marker
3209unsigned CjfifDecode::DecodeApp2IccProfile(unsigned nLen)
3210{
3211 CString strTmp;
3212 unsigned nMarkerSeqNum; // Byte
3213 unsigned nNumMarkers; // Byte
3214 unsigned nPayloadLen; // Len of this ICC marker payload
3215
3216 unsigned nMarkerPosStart;
3217
3218 nMarkerSeqNum = Buf(m_nPos++);
3219 nNumMarkers = Buf(m_nPos++);
3220 nPayloadLen = nLen - 2 - 12 - 2; // TODO: check?
3221
3222 strTmp.Format(_T(" Marker Number = %u of %u"),nMarkerSeqNum,nNumMarkers);
3223 m_pLog->AddLine(strTmp);
3224
3225 if (nMarkerSeqNum == 1) {
3226 nMarkerPosStart = m_nPos;
3227 DecodeIccHeader(nMarkerPosStart);
3228 } else {
3229 m_pLog->AddLineWarn(_T(" Only support decode of 1st ICC Marker"));
3230 }
3231
3232 return 0;
3233}
3234
3235// Parser for APP2 FlashPix marker
3236unsigned CjfifDecode::DecodeApp2Flashpix()

Callers

nothing calls this directly

Calls 2

AddLineMethod · 0.80
AddLineWarnMethod · 0.80

Tested by

no test coverage detected