diff --git a/base/CMakeLists.txt b/base/CMakeLists.txt index 13aaf57eb..28a54417d 100755 --- a/base/CMakeLists.txt +++ b/base/CMakeLists.txt @@ -554,16 +554,7 @@ SET(UT_FILES test/test_utils.h test/filewritermodule_tests.cpp test/logger_tests.cpp - test/filewritermodule_tests.cpp - test/logger_tests.cpp -# test/logger_stress_tests.cpp #todo this test needs to be improved and added - test/quepushstrategy_tests.cpp - test/framesmuxer_tests.cpp - test/filereadermodule_tests.cpp - test/merge_tests.cpp - test/split_tests.cpp - test/imagemetadata_tests.cpp - test/bmpconverter_tests.cpp +# test/logger_stress_tests.cpp #todo this test needs to be improved and added test/quepushstrategy_tests.cpp test/framesmuxer_tests.cpp test/filereadermodule_tests.cpp @@ -590,38 +581,12 @@ SET(UT_FILES test/textoverlayxform_tests.cpp test/mp4writersink_tests.cpp test/pipeline_tests.cpp - test/findexstrategy_tests.cpp - test/jpegdecodercv_tests.cpp - test/Imageresizecv_tests.cpp - test/faciallandmarkscv_tests.cpp - test/imageviewermodule_tests.cpp - test/ImageEncodeCV_tests.cpp - test/rotatecv_tests.cpp - test/affinetransform_tests.cpp - test/brightness_contrast_tests.cpp - test/virtualptz_tests.cpp - test/webcam_source_tests.cpp - test/facedetectorXform_tests.cpp - test/sound_record_tests.cpp - test/pullstratergy_tests.cpp - test/QRReader_tests.cpp - test/textoverlayxform_tests.cpp - test/mp4writersink_tests.cpp - test/pipeline_tests.cpp # test/multiple_pipeline_tests.cpp #todo this test needs to be improved and added test/valveModule_tests.cpp test/color_conversion_tests.cpp test/archivespacemanager_tests.cpp test/multimediaqueuexform_tests.cpp - test/mp4readersource_tests.cpp - test/rtsp_client_tests.cpp - test/valveModule_tests.cpp - test/color_conversion_tests.cpp - test/archivespacemanager_tests.cpp - test/multimediaqueuexform_tests.cpp - test/mp4readersource_tests.cpp - test/rtsp_client_tests.cpp - test/rtsp_client_tests.cpp + test/mp4readersource_tests.cpp test/rtsp_client_tests.cpp test/motionvector_extractor_and_overlay_tests.cpp test/mp4_reverse_play_tests.cpp diff --git a/base/src/H264Decoder.cpp b/base/src/H264Decoder.cpp index 882fc96ab..a14b66d11 100644 --- a/base/src/H264Decoder.cpp +++ b/base/src/H264Decoder.cpp @@ -206,7 +206,7 @@ void H264Decoder::bufferBackwardEncodedFrames(frame_sp& frame, short naluType) } // insert frames into the latest gop until I frame comes. latestBackwardGop.emplace_back(frame); - H264Utils::H264_NAL_TYPE nalTypeAfterSpsPps; + H264Utils::H264_NAL_TYPE nalTypeAfterSpsPps = (H264Utils::H264_NAL_TYPE)1; if(naluType == H264Utils::H264_NAL_TYPE_SEQ_PARAM) { nalTypeAfterSpsPps = H264Utils::getNalTypeAfterSpsPps(frame->data(), frame->size()); @@ -244,7 +244,7 @@ void H264Decoder::bufferAndDecodeForwardEncodedFrames(frame_sp& frame, short nal if (!latestForwardGop.empty()) { short naluTypeOfForwardGopFirstFrame = H264Utils::getNALUType((char*)latestForwardGop.front()->data()); - H264Utils::H264_NAL_TYPE nalTypeAfterSpsPpsOfForwardGopFirstFrame; + H264Utils::H264_NAL_TYPE nalTypeAfterSpsPpsOfForwardGopFirstFrame = (H264Utils::H264_NAL_TYPE)1; if(naluTypeOfForwardGopFirstFrame == H264Utils::H264_NAL_TYPE_SEQ_PARAM) { nalTypeAfterSpsPpsOfForwardGopFirstFrame = H264Utils::getNalTypeAfterSpsPps(latestForwardGop.front()->data(), latestForwardGop.front()->size()); @@ -295,7 +295,7 @@ void H264Decoder::bufferAndDecodeForwardEncodedFrames(frame_sp& frame, short nal /* buffer fwd GOP and send the current frame */ // new GOP starts - H264Utils::H264_NAL_TYPE nalTypeAfterSpsPpsOfCurrentFrame; + H264Utils::H264_NAL_TYPE nalTypeAfterSpsPpsOfCurrentFrame = (H264Utils::H264_NAL_TYPE)1; if(naluType == H264Utils::H264_NAL_TYPE_SEQ_PARAM) { nalTypeAfterSpsPpsOfCurrentFrame = H264Utils::getNalTypeAfterSpsPps(frame->data(), frame->size()); @@ -313,7 +313,7 @@ void H264Decoder::bufferAndDecodeForwardEncodedFrames(frame_sp& frame, short nal // If direction changed to forward in the middle of GOP (Even the latest gop of backward was half and not decoded) , Then we drop the P frames until next I frame. // We also remove the entries of P frames from the incomingFramesTSQ. short latestForwardGopFirstFrameNaluType = H264Utils::getNALUType((char*)latestForwardGop.begin()->get()->data()); - H264Utils::H264_NAL_TYPE naluTypeAfterSpsPpsOfLatestForwardGopFirstFrame; + H264Utils::H264_NAL_TYPE naluTypeAfterSpsPpsOfLatestForwardGopFirstFrame = (H264Utils::H264_NAL_TYPE)1; if(latestForwardGopFirstFrameNaluType == H264Utils::H264_NAL_TYPE_SEQ_PARAM) { naluTypeAfterSpsPpsOfLatestForwardGopFirstFrame = H264Utils::getNalTypeAfterSpsPps(latestForwardGop.front()->data(), latestForwardGop.front()->size()); @@ -478,7 +478,7 @@ bool H264Decoder::process(frame_container& frames) return true; } - H264Utils::H264_NAL_TYPE nalTypeAfterSpsPpsCurrentFrame; + H264Utils::H264_NAL_TYPE nalTypeAfterSpsPpsCurrentFrame = (H264Utils::H264_NAL_TYPE)1; if(naluType == H264Utils::H264_NAL_TYPE_SEQ_PARAM) { nalTypeAfterSpsPpsCurrentFrame = H264Utils::getNalTypeAfterSpsPps(frame->data(), frame->size());