diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-30 00:46:54 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-30 00:46:54 +0000 |
commit | c7526b25874021a49c043e30decf9cefdd5b966a (patch) | |
tree | f910149ba11fbcdf0230b33e19a242d0449a4683 /chrome/gpu | |
parent | 382c29360b39b2117a74a10985b01a39ca8d524b (diff) | |
download | chromium_src-c7526b25874021a49c043e30decf9cefdd5b966a.zip chromium_src-c7526b25874021a49c043e30decf9cefdd5b966a.tar.gz chromium_src-c7526b25874021a49c043e30decf9cefdd5b966a.tar.bz2 |
Rename UploadToVideoFrame to ConvertToVideoFrame.
(Note: This was a TODO for hclam).
BUG=None
TEST=trybots
Review URL: http://codereview.chromium.org/4113006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64526 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/gpu')
-rw-r--r-- | chrome/gpu/gpu_video_decoder.cc | 9 | ||||
-rw-r--r-- | chrome/gpu/gpu_video_decoder.h | 6 | ||||
-rw-r--r-- | chrome/gpu/gpu_video_decoder_unittest.cc | 2 | ||||
-rw-r--r-- | chrome/gpu/media/fake_gl_video_decode_engine.cc | 2 | ||||
-rw-r--r-- | chrome/gpu/media/fake_gl_video_device.cc | 2 | ||||
-rw-r--r-- | chrome/gpu/media/fake_gl_video_device.h | 4 | ||||
-rw-r--r-- | chrome/gpu/media/gpu_video_device.h | 5 | ||||
-rw-r--r-- | chrome/gpu/media/mft_angle_video_device.cc | 2 | ||||
-rw-r--r-- | chrome/gpu/media/mft_angle_video_device.h | 4 |
9 files changed, 18 insertions, 18 deletions
diff --git a/chrome/gpu/gpu_video_decoder.cc b/chrome/gpu/gpu_video_decoder.cc index 27de22f..d16064c 100644 --- a/chrome/gpu/gpu_video_decoder.cc +++ b/chrome/gpu/gpu_video_decoder.cc @@ -199,9 +199,10 @@ void GpuVideoDecoder::ReleaseAllVideoFrames() { SendReleaseAllVideoFrames(); } -void GpuVideoDecoder::UploadToVideoFrame(void* buffer, - scoped_refptr<media::VideoFrame> frame, - Task* task) { +void GpuVideoDecoder::ConvertToVideoFrame( + void* buffer, + scoped_refptr<media::VideoFrame> frame, + Task* task) { // This method is called by VideoDecodeEngine to upload a buffer to a // VideoFrame. We should just delegate this to GpuVideoDevice which contains // the actual implementation. @@ -209,7 +210,7 @@ void GpuVideoDecoder::UploadToVideoFrame(void* buffer, DCHECK(ret) << "Failed to switch context"; // Actually doing the upload on the main thread. - ret = video_device_->UploadToVideoFrame(buffer, frame); + ret = video_device_->ConvertToVideoFrame(buffer, frame); DCHECK(ret) << "Failed to upload video content to a VideoFrame."; task->Run(); delete task; diff --git a/chrome/gpu/gpu_video_decoder.h b/chrome/gpu/gpu_video_decoder.h index 25885c8..79b9bdb 100644 --- a/chrome/gpu/gpu_video_decoder.h +++ b/chrome/gpu/gpu_video_decoder.h @@ -120,9 +120,9 @@ class GpuVideoDecoder int n, size_t width, size_t height, media::VideoFrame::Format format, std::vector<scoped_refptr<media::VideoFrame> >* frames, Task* task); virtual void ReleaseAllVideoFrames(); - virtual void UploadToVideoFrame(void* buffer, - scoped_refptr<media::VideoFrame> frame, - Task* task); + virtual void ConvertToVideoFrame(void* buffer, + scoped_refptr<media::VideoFrame> frame, + Task* task); virtual void Destroy(Task* task); // These methods are used in unit test only. diff --git a/chrome/gpu/gpu_video_decoder_unittest.cc b/chrome/gpu/gpu_video_decoder_unittest.cc index b1ea751..41e88d3 100644 --- a/chrome/gpu/gpu_video_decoder_unittest.cc +++ b/chrome/gpu/gpu_video_decoder_unittest.cc @@ -36,7 +36,7 @@ class MockGpuVideoDevice : public GpuVideoDevice { scoped_refptr<media::VideoFrame>*)); MOCK_METHOD1(ReleaseVideoFrame, void(const scoped_refptr<media::VideoFrame>& frame)); - MOCK_METHOD2(UploadToVideoFrame, + MOCK_METHOD2(ConvertToVideoFrame, bool(void* buffer, scoped_refptr<media::VideoFrame> frame)); private: diff --git a/chrome/gpu/media/fake_gl_video_decode_engine.cc b/chrome/gpu/media/fake_gl_video_decode_engine.cc index 532434b..db0f7a5 100644 --- a/chrome/gpu/media/fake_gl_video_decode_engine.cc +++ b/chrome/gpu/media/fake_gl_video_decode_engine.cc @@ -108,7 +108,7 @@ void FakeGlVideoDecodeEngine::ConsumeVideoSample( // After we have filled the content upload the internal frame to the // VideoFrame allocated through VideoDecodeContext. - context_->UploadToVideoFrame( + context_->ConvertToVideoFrame( internal_frame_, frame, NewRunnableMethod(this, &FakeGlVideoDecodeEngine::UploadCompleteTask, frame)); diff --git a/chrome/gpu/media/fake_gl_video_device.cc b/chrome/gpu/media/fake_gl_video_device.cc index 9e450ec..397b20f 100644 --- a/chrome/gpu/media/fake_gl_video_device.cc +++ b/chrome/gpu/media/fake_gl_video_device.cc @@ -37,7 +37,7 @@ void FakeGlVideoDevice::ReleaseVideoFrame( // for the VideoFrame(s) generated. } -bool FakeGlVideoDevice::UploadToVideoFrame( +bool FakeGlVideoDevice::ConvertToVideoFrame( void* buffer, scoped_refptr<media::VideoFrame> frame) { // Assume we are in the right context and then upload the content to the // texture. diff --git a/chrome/gpu/media/fake_gl_video_device.h b/chrome/gpu/media/fake_gl_video_device.h index 711c3ef..2075547 100644 --- a/chrome/gpu/media/fake_gl_video_device.h +++ b/chrome/gpu/media/fake_gl_video_device.h @@ -20,8 +20,8 @@ class FakeGlVideoDevice : public GpuVideoDevice { scoped_refptr<media::VideoFrame>* frame); virtual void ReleaseVideoFrame( const scoped_refptr<media::VideoFrame>& frame); - virtual bool UploadToVideoFrame(void* buffer, - scoped_refptr<media::VideoFrame> frame); + virtual bool ConvertToVideoFrame(void* buffer, + scoped_refptr<media::VideoFrame> frame); }; #endif // CHROME_GPU_MEDIA_FAKE_GL_VIDEO_DEVICE_H_ diff --git a/chrome/gpu/media/gpu_video_device.h b/chrome/gpu/media/gpu_video_device.h index 0556903..1ee4b6b 100644 --- a/chrome/gpu/media/gpu_video_device.h +++ b/chrome/gpu/media/gpu_video_device.h @@ -49,9 +49,8 @@ class GpuVideoDevice { // the GPU process. // // Return true if successful. - // TODO(hclam): Rename this to ConvertToVideoFrame(). - virtual bool UploadToVideoFrame(void* buffer, - scoped_refptr<media::VideoFrame> frame) = 0; + virtual bool ConvertToVideoFrame(void* buffer, + scoped_refptr<media::VideoFrame> frame) = 0; }; #endif // CHROME_GPU_MEDIA_GPU_VIDEO_DEVICE_H_ diff --git a/chrome/gpu/media/mft_angle_video_device.cc b/chrome/gpu/media/mft_angle_video_device.cc index 1faf9dc..56cb717 100644 --- a/chrome/gpu/media/mft_angle_video_device.cc +++ b/chrome/gpu/media/mft_angle_video_device.cc @@ -43,7 +43,7 @@ void MftAngleVideoDevice::ReleaseVideoFrame( // for the VideoFrame(s) generated. } -bool MftAngleVideoDevice::UploadToVideoFrame( +bool MftAngleVideoDevice::ConvertToVideoFrame( void* buffer, scoped_refptr<media::VideoFrame> frame) { gl::Context* context = (gl::Context*)eglGetCurrentContext(); // TODO(hclam): Connect ANGLE to upload the surface to texture when changes diff --git a/chrome/gpu/media/mft_angle_video_device.h b/chrome/gpu/media/mft_angle_video_device.h index fb1e0e8..0775a06 100644 --- a/chrome/gpu/media/mft_angle_video_device.h +++ b/chrome/gpu/media/mft_angle_video_device.h @@ -32,8 +32,8 @@ class MftAngleVideoDevice : public GpuVideoDevice { scoped_refptr<media::VideoFrame>* frame); virtual void ReleaseVideoFrame( const scoped_refptr<media::VideoFrame>& frame); - virtual bool UploadToVideoFrame(void* buffer, - scoped_refptr<media::VideoFrame> frame); + virtual bool ConvertToVideoFrame(void* buffer, + scoped_refptr<media::VideoFrame> frame); private: ScopedComPtr<IDirect3DDevice9, &IID_IDirect3DDevice9> device_; |