Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1354)

Unified Diff: webrtc/video_frame.h

Issue 1602523004: Added EncodedImage::GetBufferPaddingBytes. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: 0 additional bytes, make ios compile Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/video_frame.h
diff --git a/webrtc/video_frame.h b/webrtc/video_frame.h
index 9d2ed9fd4d978e7a487d36390c549e5c1c1ee976..497efc9d4301f6ce57a8d5eb3d928bb7b68898e3 100644
--- a/webrtc/video_frame.h
+++ b/webrtc/video_frame.h
@@ -173,6 +173,10 @@ class VideoFrame {
// TODO(pbos): Rename EncodedFrame and reformat this class' members.
class EncodedImage {
public:
+ // Some decoders require encoded image buffers to be padded with a small
+ // number of additional bytes (due to over-reading byte readers).
+ static size_t GetBufferPadding(VideoCodecType codec_type);
hbos 2016/01/19 14:22:18 (I originally wanted to place this in VideoDecoder
stefan-webrtc 2016/01/19 15:06:20 Somewhat... VideoDecoder would probably have been
hbos 2016/01/19 16:50:34 They look weird to me.
+
EncodedImage() : EncodedImage(nullptr, 0, 0) {}
EncodedImage(uint8_t* buffer, size_t length, size_t size)
: _buffer(buffer), _length(length), _size(size) {}

Powered by Google App Engine
This is Rietveld 408576698