Skip to content
Snippets Groups Projects
Commit db1ef33d authored by Adrien Béraud's avatar Adrien Béraud Committed by Philippe Gorley
Browse files

mediaframe: add const pointer method


Change-Id: Ifeaf66cf06d8859be25642064ce09761a1552894
Reviewed-by: default avatarPhilippe Gorley <philippe.gorley@savoirfairelinux.com>
parent 556061ee
No related branches found
No related tags found
No related merge requests found
...@@ -80,7 +80,8 @@ public: ...@@ -80,7 +80,8 @@ public:
virtual ~MediaFrame() = default; virtual ~MediaFrame() = default;
// Return a pointer on underlaying buffer // Return a pointer on underlaying buffer
AVFrame* pointer() const noexcept { return frame_.get(); } const AVFrame* pointer() const noexcept { return frame_.get(); }
AVFrame* pointer() noexcept { return frame_.get(); }
// Fill this MediaFrame with data from o // Fill this MediaFrame with data from o
void copyFrom(const MediaFrame& o); void copyFrom(const MediaFrame& o);
......
...@@ -310,7 +310,7 @@ MediaDecoder::decode(VideoFrame& result) ...@@ -310,7 +310,7 @@ MediaDecoder::decode(VideoFrame& result)
#endif // RING_VIDEO #endif // RING_VIDEO
MediaDecoder::Status MediaDecoder::Status
MediaDecoder::decode(const AudioFrame& decodedFrame) MediaDecoder::decode(AudioFrame& decodedFrame)
{ {
const auto frame = decodedFrame.pointer(); const auto frame = decodedFrame.pointer();
......
...@@ -89,7 +89,7 @@ class MediaDecoder { ...@@ -89,7 +89,7 @@ class MediaDecoder {
#endif // RING_VIDEO #endif // RING_VIDEO
int setupFromAudioData(); int setupFromAudioData();
Status decode(const AudioFrame&); Status decode(AudioFrame&);
void writeToRingBuffer(const AudioFrame&, RingBuffer&, const AudioFormat); void writeToRingBuffer(const AudioFrame&, RingBuffer&, const AudioFormat);
int getWidth() const; int getWidth() const;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment