[feat] save thumbnail as black picture if have not received a full frame

This commit is contained in:
dijunkun
2025-04-16 16:47:30 +08:00
parent 22aed6ea53
commit 9705374b9a
2 changed files with 27 additions and 21 deletions

View File

@@ -999,12 +999,10 @@ void Render::ProcessSdlEvent() {
DestroyStreamWindowContext();
for (auto& [host_name, props] : client_properties_) {
if (props->dst_buffer_) {
thumbnail_->SaveToThumbnail(
(char*)props->dst_buffer_, props->video_width_,
props->video_height_, host_name, props->remote_host_name_,
props->remember_password_ ? props->remote_password_ : "");
}
thumbnail_->SaveToThumbnail(
(char*)props->dst_buffer_, props->video_width_,
props->video_height_, host_name, props->remote_host_name_,
props->remember_password_ ? props->remote_password_ : "");
if (props->peer_) {
std::string client_id = (host_name == client_id_)