Index: ppapi/shared_impl/media_stream_buffer.h |
diff --git a/ppapi/shared_impl/media_stream_buffer.h b/ppapi/shared_impl/media_stream_buffer.h |
index 8b0ebe1cc40bec8f45ac007415a994e210d68634..ddb67295c346a293e62d4436bcbc98bab84415f3 100644 |
--- a/ppapi/shared_impl/media_stream_buffer.h |
+++ b/ppapi/shared_impl/media_stream_buffer.h |
@@ -11,7 +11,12 @@ |
namespace ppapi { |
union MediaStreamBuffer { |
- enum Type { TYPE_UNKNOWN = 0, TYPE_AUDIO = 1, TYPE_VIDEO = 2, }; |
+ enum Type { |
+ TYPE_UNKNOWN = 0, |
+ TYPE_AUDIO = 1, |
+ TYPE_VIDEO = 2, |
+ TYPE_BITSTREAM = 3 |
+ }; |
struct Header { |
Type type; |
@@ -41,16 +46,26 @@ union MediaStreamBuffer { |
uint8_t data[8]; |
}; |
+ struct Bitstream { |
+ Header header; |
+ uint32_t data_size; |
+ // Uses 8 bytes to make sure the Bitstream struct has consistent size |
+ // between NaCl code and renderer code. |
+ uint8_t data[8]; |
+ }; |
+ |
// Because these structs are written and read in shared memory, we need |
// the size and alighment to be consistent between NaCl and its host trusted |
// platform. |
PP_COMPILE_ASSERT_SIZE_IN_BYTES(Header, 8); |
PP_COMPILE_ASSERT_SIZE_IN_BYTES(Audio, 40); |
PP_COMPILE_ASSERT_SIZE_IN_BYTES(Video, 40); |
+ PP_COMPILE_ASSERT_SIZE_IN_BYTES(Bitstream, 20); |
Header header; |
Video video; |
Audio audio; |
+ Bitstream bitstream; |
}; |
} // namespace ppapi |