Hi,
I already have a working webrtc application (C++, M89) which can send and receive streams.
I would like to add some information to each video frames.
I made a class which inherit of webrtc::FrameEncryptorInterface
and gave it to the RtpStreamSender using the method SetFrameEncryptor
Now the problem is that the method Encrypt of my class is never called.
I found that the call of Encrypt is cancelled in RTPSenderVideo::SendVideo by this condition :
bool has_generic_descriptor =
first_packet->HasExtension<RtpGenericFrameDescriptorExtension00>() ||
first_packet->HasExtension<RtpDependencyDescriptorExtension>();
if (frame_encryptor_ != nullptr) {
if (!has_generic_descriptor) {
return false;
}
How can I add one of these extensions to pass the condition ?
Is there a better or a more simple way to add information to a frame ?
Regards,
Christophe Chaillon