| Index: media/gpu/vt_video_decode_accelerator_mac.h
|
| diff --git a/content/common/gpu/media/vt_video_decode_accelerator_mac.h b/media/gpu/vt_video_decode_accelerator_mac.h
|
| similarity index 91%
|
| rename from content/common/gpu/media/vt_video_decode_accelerator_mac.h
|
| rename to media/gpu/vt_video_decode_accelerator_mac.h
|
| index 33440badcda492fdc35b5e23ca1be960b7c8f436..77d3915a97e272a6db3156f14584288f4abad582 100644
|
| --- a/content/common/gpu/media/vt_video_decode_accelerator_mac.h
|
| +++ b/media/gpu/vt_video_decode_accelerator_mac.h
|
| @@ -18,16 +18,16 @@
|
| #include "base/message_loop/message_loop.h"
|
| #include "base/threading/thread.h"
|
| #include "base/threading/thread_checker.h"
|
| -#include "content/common/gpu/media/gpu_video_decode_accelerator_helpers.h"
|
| -#include "content/common/gpu/media/vt_mac.h"
|
| #include "media/filters/h264_parser.h"
|
| +#include "media/gpu/gpu_video_decode_accelerator_helpers.h"
|
| +#include "media/gpu/vt_mac.h"
|
| #include "media/video/h264_poc.h"
|
| #include "media/video/video_decode_accelerator.h"
|
| #include "ui/gfx/geometry/size.h"
|
| #include "ui/gl/gl_context_cgl.h"
|
| #include "ui/gl/gl_image_io_surface.h"
|
|
|
| -namespace content {
|
| +namespace media {
|
|
|
| // Preload VideoToolbox libraries, needed for sandbox warmup.
|
| bool InitializeVideoToolbox();
|
| @@ -57,13 +57,12 @@ class VTVideoDecodeAccelerator : public media::VideoDecodeAccelerator {
|
| override;
|
|
|
| // Called by OutputThunk() when VideoToolbox finishes decoding a frame.
|
| - void Output(
|
| - void* source_frame_refcon,
|
| - OSStatus status,
|
| - CVImageBufferRef image_buffer);
|
| + void Output(void* source_frame_refcon,
|
| + OSStatus status,
|
| + CVImageBufferRef image_buffer);
|
|
|
| static media::VideoDecodeAccelerator::SupportedProfiles
|
| - GetSupportedProfiles();
|
| + GetSupportedProfiles();
|
|
|
| private:
|
| // Logged to UMA, so never reuse values. Make sure to update
|
| @@ -152,10 +151,9 @@ class VTVideoDecodeAccelerator : public media::VideoDecodeAccelerator {
|
|
|
| // Compute the |pic_order_cnt| for a frame. Returns true or calls
|
| // NotifyError() before returning false.
|
| - bool ComputePicOrderCnt(
|
| - const media::H264SPS* sps,
|
| - const media::H264SliceHeader& slice_hdr,
|
| - Frame* frame);
|
| + bool ComputePicOrderCnt(const media::H264SPS* sps,
|
| + const media::H264SliceHeader& slice_hdr,
|
| + Frame* frame);
|
|
|
| // Set up VideoToolbox using the current SPS and PPS. Returns true or calls
|
| // NotifyError() before returning false.
|
| @@ -172,9 +170,8 @@ class VTVideoDecodeAccelerator : public media::VideoDecodeAccelerator {
|
| //
|
| // Methods for interacting with |client_|. Run on |gpu_task_runner_|.
|
| //
|
| - void NotifyError(
|
| - Error vda_error_type,
|
| - VTVDASessionFailureType session_failure_type);
|
| + void NotifyError(Error vda_error_type,
|
| + VTVDASessionFailureType session_failure_type);
|
|
|
| // |type| is the type of task that the flush will complete, one of TASK_FLUSH,
|
| // TASK_RESET, or TASK_DESTROY.
|
| @@ -210,15 +207,15 @@ class VTVideoDecodeAccelerator : public media::VideoDecodeAccelerator {
|
|
|
| // Utility class to define the order of frames in the reorder queue.
|
| struct FrameOrder {
|
| - bool operator()(
|
| - const linked_ptr<Frame>& lhs,
|
| - const linked_ptr<Frame>& rhs) const;
|
| + bool operator()(const linked_ptr<Frame>& lhs,
|
| + const linked_ptr<Frame>& rhs) const;
|
| };
|
|
|
| // Queue of decoded frames in presentation order.
|
| std::priority_queue<linked_ptr<Frame>,
|
| std::vector<linked_ptr<Frame>>,
|
| - FrameOrder> reorder_queue_;
|
| + FrameOrder>
|
| + reorder_queue_;
|
|
|
| // Size of assigned picture buffers.
|
| gfx::Size picture_size_;
|
| @@ -275,6 +272,6 @@ class VTVideoDecodeAccelerator : public media::VideoDecodeAccelerator {
|
| DISALLOW_COPY_AND_ASSIGN(VTVideoDecodeAccelerator);
|
| };
|
|
|
| -} // namespace content
|
| +} // namespace media
|
|
|
| #endif // CONTENT_COMMON_GPU_MEDIA_VT_VIDEO_DECODE_ACCELERATOR_H_
|
|
|