Hi, I can't pass a non-const pointer into getRTPSinkandRTCP as it will fail to compile:
error: no matching function for call to ‘ServerMediaSubsession::getRTPSinkandRTCP(void*&, RTPSink*&, const RTCPInstance*&)’ fStreamStates[count].subsession->getRTPSinkandRTCP(fStreamStates[count].streamToken, Sink, Instance); ^ note: candidate is: ServerMediaSubsession::getRTPSinkandRTCP(void*, const RTPSink*&, const RTCPInstance*&) I've worked around it at the moment by using a const_cast on the returned RTPSink pointer to remove the 'const'-ness of it. This isn't ideal though. Andy From: live-devel <live-devel-boun...@us.live555.com> on behalf of Ross Finlayson <finlay...@live555.com> Sent: 08 November 2023 09:33 To: LIVE555 Streaming Media - development & use <live-de...@us.live555.com> Subject: Re: [Live-devel] Retrieving stats for ProxyServerMediaSession > On Nov 8, 2023, at 1:23 AM, Andy Hawkins <andy.hawk...@uniguest.com> wrote: > > Hi, > > Thanks again, that's very helpful. > > One remaining issue, the 'getRTPSinkandRTCP' method in returns *const* > pointers, but the RTPSink member 'getTotalBitrate' is not a const method, so > can't be called from these pointers. Correct. “getTotalBitrate()” modifies the state of the object (to reset the ‘last called time’ and counter), so it can’t be const. So, in the pseudo code I included in my last email, the declaration of “rtpSink” should have been RTPSink* rtpSink; (at least, if you want to call “getTotalBitrate()” Ross Finlayson Live Networks, Inc. http://www.live555.com/ _______________________________________________ live-devel mailing list live-devel@lists.live555.com http://lists.live555.com/mailman/listinfo/live-devel _______________________________________________ live-devel mailing list live-devel@lists.live555.com http://lists.live555.com/mailman/listinfo/live-devel