MCPcopy Create free account
hub / github.com/darktable-org/rawspeed / getDecoder

Method getDecoder

src/librawspeed/parsers/CiffParser.cpp:65–80  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

63}
64
65std::unique_ptr<RawDecoder> CiffParser::getDecoder(const CameraMetaData* meta) {
66 if (!mRootIFD)
67 parseData();
68
69 const auto potentials(mRootIFD->getIFDsWithTag(CIFF_MAKEMODEL));
70
71 for (const auto& potential : potentials) {
72 const auto* const mm = potential->getEntry(CIFF_MAKEMODEL);
73 const string make = trimSpaces(mm->getString());
74
75 if (make == "Canon")
76 return std::make_unique<CrwDecoder>(move(mRootIFD), mInput);
77 }
78
79 ThrowCPE("No decoder found. Sorry.");
80}
81
82} // namespace rawspeed

Callers

nothing calls this directly

Calls 4

trimSpacesFunction · 0.85
getIFDsWithTagMethod · 0.45
getEntryMethod · 0.45
getStringMethod · 0.45

Tested by

no test coverage detected