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

Side by Side Diff: content/renderer/pepper/ppb_video_decoder_impl.cc

Issue 1677133003: Implemented parsing of HEVC codec ids (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@parse-codec-id
Patch Set: Updated comments about VideoCodecProfile enum Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/pepper/ppb_video_decoder_impl.h" 5 #include "content/renderer/pepper/ppb_video_decoder_impl.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 case PP_VIDEODECODER_H264PROFILE_SCALABLEBASELINE: 59 case PP_VIDEODECODER_H264PROFILE_SCALABLEBASELINE:
60 return media::H264PROFILE_SCALABLEBASELINE; 60 return media::H264PROFILE_SCALABLEBASELINE;
61 case PP_VIDEODECODER_H264PROFILE_SCALABLEHIGH: 61 case PP_VIDEODECODER_H264PROFILE_SCALABLEHIGH:
62 return media::H264PROFILE_SCALABLEHIGH; 62 return media::H264PROFILE_SCALABLEHIGH;
63 case PP_VIDEODECODER_H264PROFILE_STEREOHIGH: 63 case PP_VIDEODECODER_H264PROFILE_STEREOHIGH:
64 return media::H264PROFILE_STEREOHIGH; 64 return media::H264PROFILE_STEREOHIGH;
65 case PP_VIDEODECODER_H264PROFILE_MULTIVIEWHIGH: 65 case PP_VIDEODECODER_H264PROFILE_MULTIVIEWHIGH:
66 return media::H264PROFILE_MULTIVIEWHIGH; 66 return media::H264PROFILE_MULTIVIEWHIGH;
67 case PP_VIDEODECODER_VP8PROFILE_ANY: 67 case PP_VIDEODECODER_VP8PROFILE_ANY:
68 return media::VP8PROFILE_ANY; 68 return media::VP8PROFILE_ANY;
69 case PP_VIDEODECODER_VP9PROFILE_ANY:
70 return media::VP9PROFILE_ANY;
71 case PP_VIDEODECODER_HEVCPROFILE_MAIN:
72 return media::HEVCPROFILE_MAIN;
73 case PP_VIDEODECODER_HEVCPROFILE_MAIN10:
74 return media::HEVCPROFILE_MAIN10;
75 case PP_VIDEODECODER_HEVCPROFILE_MAIN_STILL_PICTURE:
76 return media::HEVCPROFILE_MAIN_STILL_PICTURE;
69 default: 77 default:
70 return media::VIDEO_CODEC_PROFILE_UNKNOWN; 78 return media::VIDEO_CODEC_PROFILE_UNKNOWN;
71 } 79 }
72 } 80 }
73 81
74 PP_VideoDecodeError_Dev MediaToPPError( 82 PP_VideoDecodeError_Dev MediaToPPError(
75 media::VideoDecodeAccelerator::Error error) { 83 media::VideoDecodeAccelerator::Error error) {
76 switch (error) { 84 switch (error) {
77 case media::VideoDecodeAccelerator::ILLEGAL_STATE: 85 case media::VideoDecodeAccelerator::ILLEGAL_STATE:
78 return PP_VIDEODECODERERROR_ILLEGAL_STATE; 86 return PP_VIDEODECODERERROR_ILLEGAL_STATE;
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 DCHECK(RenderThreadImpl::current()); 298 DCHECK(RenderThreadImpl::current());
291 RunBitstreamBufferCallback(bitstream_buffer_id, PP_OK); 299 RunBitstreamBufferCallback(bitstream_buffer_id, PP_OK);
292 } 300 }
293 301
294 void PPB_VideoDecoder_Impl::NotifyFlushDone() { 302 void PPB_VideoDecoder_Impl::NotifyFlushDone() {
295 DCHECK(RenderThreadImpl::current()); 303 DCHECK(RenderThreadImpl::current());
296 RunFlushCallback(PP_OK); 304 RunFlushCallback(PP_OK);
297 } 305 }
298 306
299 } // namespace content 307 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698