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

Unified Diff: media/base/bitstream_buffer.cc

Issue 1541353002: Add offset support to BitstreamBuffer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Handle the offset with a helper class Created 5 years 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
« media/base/bitstream_buffer.h ('K') | « media/base/bitstream_buffer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/bitstream_buffer.cc
diff --git a/media/base/bitstream_buffer.cc b/media/base/bitstream_buffer.cc
index 5491bcb2de1ac13f0c81a3ee80b95a1f69e6103f..b19fe8b7cae50233cf1d4c8733c6a6b576d5630e 100644
--- a/media/base/bitstream_buffer.cc
+++ b/media/base/bitstream_buffer.cc
@@ -9,18 +9,29 @@ namespace media {
BitstreamBuffer::BitstreamBuffer(int32 id,
base::SharedMemoryHandle handle,
size_t size)
- : id_(id),
- handle_(handle),
- size_(size),
- presentation_timestamp_(kNoTimestamp()) {}
+ : BitstreamBuffer(id, handle, size, 0, kNoTimestamp()) {}
+
+BitstreamBuffer::BitstreamBuffer(int32 id,
+ base::SharedMemoryHandle handle,
+ size_t size,
+ off_t offset)
+ : BitstreamBuffer(id, handle, size, offset, kNoTimestamp()) {}
+
+BitstreamBuffer::BitstreamBuffer(int32 id,
+ base::SharedMemoryHandle handle,
+ size_t size,
+ base::TimeDelta presentation_timestamp)
+ : BitstreamBuffer(id, handle, size, 0, presentation_timestamp) {}
BitstreamBuffer::BitstreamBuffer(int32 id,
base::SharedMemoryHandle handle,
size_t size,
+ off_t offset,
base::TimeDelta presentation_timestamp)
: id_(id),
handle_(handle),
size_(size),
+ offset_(offset),
presentation_timestamp_(presentation_timestamp) {}
BitstreamBuffer::~BitstreamBuffer() {}
« media/base/bitstream_buffer.h ('K') | « media/base/bitstream_buffer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698