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

Unified Diff: media/capture/video/win/video_capture_device_mf_win.cc

Issue 2870263002: Rename ScopedComPtr::Receive to ScopedComPtr::GetAddressOf (Closed)
Patch Set: Rebase to 2a6f440 Created 3 years, 7 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
Index: media/capture/video/win/video_capture_device_mf_win.cc
diff --git a/media/capture/video/win/video_capture_device_mf_win.cc b/media/capture/video/win/video_capture_device_mf_win.cc
index ea1abd7f12875793a01c1978e0d62399ddc2dd17..6c91d2031f85597f655be1cd6fc6fabca5cf69c8 100644
--- a/media/capture/video/win/video_capture_device_mf_win.cc
+++ b/media/capture/video/win/video_capture_device_mf_win.cc
@@ -63,7 +63,7 @@ HRESULT FillCapabilities(IMFSourceReader* source,
ScopedComPtr<IMFMediaType> type;
HRESULT hr;
while (SUCCEEDED(hr = source->GetNativeMediaType(
- kFirstVideoStream, stream_index, type.Receive()))) {
+ kFirstVideoStream, stream_index, type.GetAddressOf()))) {
VideoCaptureFormat format;
if (FillFormat(type.Get(), &format))
capabilities->emplace_back(stream_index, format);
@@ -123,7 +123,7 @@ class MFReaderCallback final
for (DWORD i = 0; i < count; ++i) {
ScopedComPtr<IMFMediaBuffer> buffer;
- sample->GetBufferByIndex(i, buffer.Receive());
+ sample->GetBufferByIndex(i, buffer.GetAddressOf());
if (buffer.Get()) {
DWORD length = 0, max_length = 0;
BYTE* data = NULL;
@@ -202,14 +202,14 @@ bool VideoCaptureDeviceMFWin::Init(
DCHECK(!reader_.Get());
ScopedComPtr<IMFAttributes> attributes;
- MFCreateAttributes(attributes.Receive(), 1);
+ MFCreateAttributes(attributes.GetAddressOf(), 1);
DCHECK(attributes.Get());
callback_ = new MFReaderCallback(this);
attributes->SetUnknown(MF_SOURCE_READER_ASYNC_CALLBACK, callback_.get());
return SUCCEEDED(MFCreateSourceReaderFromMediaSource(
- source.Get(), attributes.Get(), reader_.Receive()));
+ source.Get(), attributes.Get(), reader_.GetAddressOf()));
}
void VideoCaptureDeviceMFWin::AllocateAndStart(
@@ -230,8 +230,9 @@ void VideoCaptureDeviceMFWin::AllocateAndStart(
const CapabilityWin found_capability =
GetBestMatchedCapability(params.requested_format, capabilities);
ScopedComPtr<IMFMediaType> type;
- hr = reader_->GetNativeMediaType(
- kFirstVideoStream, found_capability.stream_index, type.Receive());
+ hr = reader_->GetNativeMediaType(kFirstVideoStream,
+ found_capability.stream_index,
+ type.GetAddressOf());
if (SUCCEEDED(hr)) {
hr = reader_->SetCurrentMediaType(kFirstVideoStream, NULL, type.Get());
if (SUCCEEDED(hr)) {
« no previous file with comments | « media/capture/video/win/video_capture_device_factory_win.cc ('k') | media/capture/video/win/video_capture_device_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698