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

Unified Diff: ppapi/proxy/media_stream_audio_track_resource.cc

Issue 142023008: [PPAPI][MediaStream] Rename AudioFrame to AudioBuffer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix review issues Created 6 years, 10 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 | « ppapi/proxy/media_stream_audio_track_resource.h ('k') | ppapi/proxy/media_stream_track_resource_base.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/media_stream_audio_track_resource.cc
diff --git a/ppapi/proxy/media_stream_audio_track_resource.cc b/ppapi/proxy/media_stream_audio_track_resource.cc
index 10956ab30d9c8617000845a750553ffbb4c35e75..951bda8356e7dbe0e7ca01cddca16a67dd1836c9 100644
--- a/ppapi/proxy/media_stream_audio_track_resource.cc
+++ b/ppapi/proxy/media_stream_audio_track_resource.cc
@@ -5,7 +5,7 @@
#include "ppapi/proxy/media_stream_audio_track_resource.h"
#include "ppapi/proxy/audio_frame_resource.h"
-#include "ppapi/shared_impl/media_stream_frame.h"
+#include "ppapi/shared_impl/media_stream_buffer.h"
#include "ppapi/shared_impl/var.h"
namespace ppapi {
@@ -84,9 +84,9 @@ int32_t MediaStreamAudioTrackResource::RecycleFrame(PP_Resource frame) {
if (has_ended())
return PP_OK;
- DCHECK_GE(frame_resource->GetFrameBufferIndex(), 0);
+ DCHECK_GE(frame_resource->GetBufferIndex(), 0);
- SendEnqueueFrameMessageToHost(frame_resource->GetFrameBufferIndex());
+ SendEnqueueBufferMessageToHost(frame_resource->GetBufferIndex());
frame_resource->Invalidate();
return PP_OK;
}
@@ -106,7 +106,7 @@ void MediaStreamAudioTrackResource::Close() {
MediaStreamTrackResourceBase::CloseInternal();
}
-void MediaStreamAudioTrackResource::OnNewFrameEnqueued() {
+void MediaStreamAudioTrackResource::OnNewBufferEnqueued() {
if (!TrackedCallback::IsPending(get_frame_callback_))
return;
@@ -119,14 +119,14 @@ void MediaStreamAudioTrackResource::OnNewFrameEnqueued() {
}
PP_Resource MediaStreamAudioTrackResource::GetAudioFrame() {
- int32_t index = frame_buffer()->DequeueFrame();
+ int32_t index = buffer_manager()->DequeueBuffer();
if (index < 0)
return 0;
- MediaStreamFrame* frame = frame_buffer()->GetFramePointer(index);
- DCHECK(frame);
+ MediaStreamBuffer* buffer = buffer_manager()->GetBufferPointer(index);
+ DCHECK(buffer);
scoped_refptr<AudioFrameResource> resource =
- new AudioFrameResource(pp_instance(), index, frame);
+ new AudioFrameResource(pp_instance(), index, buffer);
// Add |pp_resource()| and |resource| into |frames_|.
// |frames_| uses scoped_ptr<> to hold a ref of |resource|. It keeps the
// resource alive.
« no previous file with comments | « ppapi/proxy/media_stream_audio_track_resource.h ('k') | ppapi/proxy/media_stream_track_resource_base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698