| 143 | } |
| 144 | |
| 145 | nvimgcodecProcessingStatus_t ImageGenericDecoder::canProcessImpl(Entry& sample, ProcessorEntry* processor, int tid) noexcept { |
| 146 | NVIMGCODEC_LOG_TRACE(this->logger_, tid << ": " << processor->id_ << " canDecode #" << sample.sample_idx); |
| 147 | nvimgcodecProcessingStatus_t status; |
| 148 | try { |
| 149 | processor->instance_->canDecode( |
| 150 | sample.getImageDesc(), sample.code_stream->getCodeStreamDesc(), curr_params_, &status, tid); |
| 151 | NVIMGCODEC_LOG_DEBUG( |
| 152 | this->logger_, tid << ": " << processor->id_ << " canDecode #" << sample.sample_idx << " returned " << status); |
| 153 | return status; |
| 154 | } catch (const std::exception& e) { |
| 155 | NVIMGCODEC_LOG_ERROR(logger_, "Exception during canDecode: " << e.what()); |
| 156 | return NVIMGCODEC_PROCESSING_STATUS_FAIL; |
| 157 | } |
| 158 | } |
| 159 | |
| 160 | bool ImageGenericDecoder::processImpl(Entry& sample, int tid) noexcept { |
| 161 | try { |
no test coverage detected