Add groupCallParticipantVideoInfo.is_paused.

This commit is contained in:
levlam 2021-06-01 22:34:50 +03:00
parent b074bce314
commit 0202ade138
3 changed files with 6 additions and 3 deletions

View File

@ -2175,7 +2175,8 @@ groupCall id:int32 title:string scheduled_start_date:int32 enabled_start_notific
groupCallVideoSourceGroup semantics:string source_ids:vector<int32> = GroupCallVideoSourceGroup;
//@description Contains information about a group call participant's video channel @source_groups List of synchronization source groups of the video @endpoint_id Video channel endpoint identifier
groupCallParticipantVideoInfo source_groups:vector<groupCallVideoSourceGroup> endpoint_id:string = GroupCallParticipantVideoInfo;
//@is_paused True if the video is paused. This flag needs to be ignored, if new video frames are received
groupCallParticipantVideoInfo source_groups:vector<groupCallVideoSourceGroup> endpoint_id:string is_paused:Bool = GroupCallParticipantVideoInfo;
//@description Represents a group call participant
//@participant_id Identifier of the group call participant

View File

@ -15,7 +15,7 @@ static bool operator==(const GroupCallVideoSourceGroup &lhs, const GroupCallVide
}
bool operator==(const GroupCallVideoPayload &lhs, const GroupCallVideoPayload &rhs) {
return lhs.source_groups == rhs.source_groups && lhs.endpoint == rhs.endpoint;
return lhs.source_groups == rhs.source_groups && lhs.endpoint == rhs.endpoint && lhs.is_paused == rhs.is_paused;
}
static td_api::object_ptr<td_api::groupCallVideoSourceGroup> get_group_call_video_source_group_object(
@ -29,7 +29,7 @@ td_api::object_ptr<td_api::groupCallParticipantVideoInfo> get_group_call_partici
return nullptr;
}
return td_api::make_object<td_api::groupCallParticipantVideoInfo>(
transform(payload.source_groups, get_group_call_video_source_group_object), payload.endpoint);
transform(payload.source_groups, get_group_call_video_source_group_object), payload.endpoint, payload.is_paused);
}
GroupCallVideoPayload get_group_call_video_payload(const telegram_api::groupCallParticipantVideo *video) {
@ -41,6 +41,7 @@ GroupCallVideoPayload get_group_call_video_payload(const telegram_api::groupCall
result.source_ids = source_group->sources_;
return result;
});
result.is_paused = video->paused_;
return result;
}

View File

@ -22,6 +22,7 @@ struct GroupCallVideoSourceGroup {
struct GroupCallVideoPayload {
vector<GroupCallVideoSourceGroup> source_groups;
string endpoint;
bool is_paused = false;
};
bool operator==(const GroupCallVideoPayload &lhs, const GroupCallVideoPayload &rhs);