Index: webrtc/test/fake_texture_frame.h |
diff --git a/webrtc/test/fake_texture_frame.h b/webrtc/test/fake_texture_frame.h |
index 5e7571d87b839d79e7e8b60a8dc3e7d41bc8fda6..9429eb74ce1c43d0976c472da0c80a17bdccc76e 100644 |
--- a/webrtc/test/fake_texture_frame.h |
+++ b/webrtc/test/fake_texture_frame.h |
@@ -10,9 +10,9 @@ |
#ifndef WEBRTC_TEST_FAKE_TEXTURE_FRAME_H_ |
#define WEBRTC_TEST_FAKE_TEXTURE_FRAME_H_ |
+#include "webrtc/api/video/video_frame.h" |
#include "webrtc/base/checks.h" |
#include "webrtc/common_video/include/video_frame_buffer.h" |
-#include "webrtc/video_frame.h" |
namespace webrtc { |
namespace test { |
@@ -39,11 +39,7 @@ class FakeNativeHandleBuffer : public NativeHandleBuffer { |
private: |
rtc::scoped_refptr<VideoFrameBuffer> NativeToI420Buffer() override { |
rtc::scoped_refptr<I420Buffer> buffer = I420Buffer::Create(width_, height_); |
- int half_height = (height_ + 1) / 2; |
- int half_width = (width_ + 1) / 2; |
- memset(buffer->MutableDataY(), 0, height_ * width_); |
- memset(buffer->MutableDataU(), 0, half_height * half_width); |
- memset(buffer->MutableDataV(), 0, half_height * half_width); |
+ buffer->InitializeData(); |
the sun
2016/12/05 22:36:29
SetToBlack()? Do we really need both SetToBlack an
nisse-webrtc
2016/12/06 12:02:15
Probably not. Do you want InitializeData deleted i
the sun
2016/12/07 15:43:51
Not necessarily, but if you intend to delete it, d
nisse-webrtc
2016/12/13 15:08:02
Done. Have to keep the old method for compatibilit
the sun
2016/12/13 15:29:28
Sure.
|
return buffer; |
} |
}; |