提交 f0b85e5e authored 作者: blu's avatar blu

evmlmotion cpu optimazition

上级 1f124a47
...@@ -97,5 +97,6 @@ ...@@ -97,5 +97,6 @@
"variant": "cpp", "variant": "cpp",
"format": "cpp" "format": "cpp"
}, },
"C_Cpp.errorSquiggles": "Disabled" "C_Cpp.errorSquiggles": "Disabled",
"git.ignoreLimitWarning": true
} }
\ No newline at end of file
...@@ -491,15 +491,7 @@ private: ...@@ -491,15 +491,7 @@ private:
pFrame->key_frame, pFrame->key_frame,
pFrame->coded_picture_number pFrame->coded_picture_number
); );
// string name = urlOut + "/"+ to_string(chrono::duration_cast<chrono::seconds>(chrono::system_clock::now().time_since_epoch()).count()) + ".pgm";
// TODO: dynamic pps adapting
// if(this->schmittriStatus == 0 && this->pktLag >= 10) {
// this->schmittriStatus = 1;
// }else if(this->schmittriStatus == 1 && this->pktLag <= 5){
// this->schmittriStatus = 2;
// }else if(this->schmittriStatus == 2 && this->pktLag < 10) {
// this->schmittriStatus = 0;
// }
static long long called = 0; static long long called = 0;
static int factor = 0; static int factor = 0;
called++; called++;
...@@ -522,7 +514,7 @@ private: ...@@ -522,7 +514,7 @@ private:
if(this->pps != 0 && (called %180) == 0) { if(this->pps != 0 && (called %180) == 0) {
spdlog::info("evmlmotion {} pps {}, fpsFactor {}, called {}, lag {}, skip processing", this->selfId, this->pps, factor, called, this->pktLag); spdlog::info("evmlmotion {} pps {}, fpsFactor {}, called {}, lag {}, skip processing", this->selfId, this->pps, factor, called, this->pktLag);
} }
detectMotion(pCodecContext->pix_fmt, pFrame, false); // detectMotion(pCodecContext->pix_fmt, pFrame, false);
}else{ }else{
if((called % (180*4)) == 0){ if((called % (180*4)) == 0){
spdlog::info("evmlmotion {} pps {}, fpsFactor {}, called {}, lag {}", this->selfId, this->pps, factor, called, this->pktLag); spdlog::info("evmlmotion {} pps {}, fpsFactor {}, called {}, lag {}", this->selfId, this->pps, factor, called, this->pktLag);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论