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

Unified Diff: webrtc/test/fake_texture_frame.h

Issue 2517173004: Move VideoFrame and related declarations to webrtc/api/video. (Closed)
Patch Set: Make rotation check clearer. Created 3 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
« no previous file with comments | « webrtc/test/fake_decoder.cc ('k') | webrtc/test/fake_videorenderer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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..c857f483436c8bf44a0906029ffa2050c95ece77 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);
+ I420Buffer::SetBlack(buffer);
return buffer;
}
};
« no previous file with comments | « webrtc/test/fake_decoder.cc ('k') | webrtc/test/fake_videorenderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698