Update VideoStack.cpp

修正编译报错问题
This commit is contained in:
ljx0305 2024-03-19 09:39:33 +08:00 committed by GitHub
parent 5a137f8b8e
commit 0c32c9aea7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 4 deletions

View File

@ -180,7 +180,7 @@ void StackPlayer::play()
self->onFrame(frame);
});
videoTrack->addDelegate((std::function<bool(const mediakit::Frame::Ptr&)>)[decoder](const mediakit::Frame::Ptr& frame) {
videoTrack->addDelegate([decoder](const mediakit::Frame::Ptr& frame) {
return decoder->inputFrame(frame, false, true);
});
}
@ -467,8 +467,8 @@ Params VideoStackManager::parseParams(const Json::Value& json,
float gaph = json["gaph"].asFloat(); //水平间距
//单个间距
int gaphPix = static_cast<int>(std::round(width * gaph));
int gapvPix = static_cast<int>(std::round(height * gapv));
int gaphPix = static_cast<int>(round(width * gaph));
int gapvPix = static_cast<int>(round(height * gapv));
// 根据间距计算格子宽高
int gridWidth = cols > 1 ? (width - gaphPix * (cols - 1)) / cols : width;
@ -587,4 +587,4 @@ StackPlayer::Ptr VideoStackManager::createPlayer(const std::string& id)
return player;
}
#endif
#endif