| 43 | } |
| 44 | |
| 45 | std::unique_ptr<IImageParser> CodecRegistry::getParser( |
| 46 | nvimgcodecCodeStreamDesc_t* code_stream) const { |
| 47 | NVIMGCODEC_LOG_TRACE(logger_, "CodecRegistry::getParser"); |
| 48 | for (auto* codec : codec_ptrs_) { |
| 49 | std::unique_ptr<IImageParser> parser = codec->createParser(code_stream); |
| 50 | if (parser) { |
| 51 | return parser; |
| 52 | } |
| 53 | } |
| 54 | |
| 55 | return nullptr; |
| 56 | } |
| 57 | |
| 58 | ICodec* CodecRegistry::getCodecByName(const char* name) { |
| 59 | auto it = by_name_.find(name); |
nothing calls this directly
no test coverage detected