void avi_reader_c::identify_video() { if (!m_video_track_ok) return; auto info = mtx::id::info_c{}; auto codec = codec_c::look_up(AVI_video_compressor(m_avi)); auto fourcc_str = fourcc_c{AVI_video_compressor(m_avi)}.description(); if (codec.is(codec_c::type_e::V_MPEG4_P2)) extended_identify_mpeg4_l2(info); else if (codec.is(codec_c::type_e::V_MPEG4_P10)) info.add(mtx::id::packetizer, mtx::id::mpeg4_p10_es_video); info.add(mtx::id::pixel_dimensions, boost::format("%1%x%2%") % AVI_video_width(m_avi) % AVI_video_height(m_avi)); id_result_track(0, ID_RESULT_TRACK_VIDEO, codec.get_name(fourcc_str), join(" ", info.get())); }
void avi_reader_c::identify_video() { if (!m_video_track_ok) return; std::vector<std::string> extended_info; const char *fourcc_str = AVI_video_compressor(m_avi); std::string type = fourcc_str; if (IS_MPEG4_L2_FOURCC(fourcc_str)) extended_identify_mpeg4_l2(extended_info); else if (mpeg4::p10::is_avc_fourcc(fourcc_str)) extended_info.push_back("packetizer:mpeg4_p10_es_video"); else if (mpeg1_2::is_fourcc(get_uint32_le(fourcc_str))) type = "MPEG-1/2"; else if (type == "VP80") type = "VP8"; id_result_track(0, ID_RESULT_TRACK_VIDEO, type, join(" ", extended_info)); }