Add data() accessors to EncodedImage

Intend to make the |_buffer| member private, in a later cl.

Bug: webrtc:9378
Change-Id: I8398932a36d8d931a7e587edca7be3957bbafcfd
Reviewed-on: https://webrtc-review.googlesource.com/c/116782
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26201}
diff --git a/api/video/encoded_image.h b/api/video/encoded_image.h
index 4497c8d..ed1bb4b 100644
--- a/api/video/encoded_image.h
+++ b/api/video/encoded_image.h
@@ -79,6 +79,9 @@
     capacity_ = capacity;
   }
 
+  uint8_t* data() { return _buffer; }
+  const uint8_t* data() const { return _buffer; }
+
   uint32_t _encodedWidth = 0;
   uint32_t _encodedHeight = 0;
   // NTP time of the capture time in local timebase in milliseconds.