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

Side by Side Diff: content/common/gpu/media/v4l2_video_encode_accelerator.cc

Issue 1769593002: Add 4 VP9 profiles to the media::VideoCodecProfile enum. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@hevc-codec-7
Patch Set: Added some comments and dchecks Created 4 years, 8 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 <fcntl.h> 5 #include <fcntl.h>
6 #include <linux/videodev2.h> 6 #include <linux/videodev2.h>
7 #include <poll.h> 7 #include <poll.h>
8 #include <string.h> 8 #include <string.h>
9 #include <sys/eventfd.h> 9 #include <sys/eventfd.h>
10 #include <sys/ioctl.h> 10 #include <sys/ioctl.h>
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 switch (fmtdesc.pixelformat) { 300 switch (fmtdesc.pixelformat) {
301 case V4L2_PIX_FMT_H264: 301 case V4L2_PIX_FMT_H264:
302 profile.profile = media::H264PROFILE_MAIN; 302 profile.profile = media::H264PROFILE_MAIN;
303 profiles.push_back(profile); 303 profiles.push_back(profile);
304 break; 304 break;
305 case V4L2_PIX_FMT_VP8: 305 case V4L2_PIX_FMT_VP8:
306 profile.profile = media::VP8PROFILE_ANY; 306 profile.profile = media::VP8PROFILE_ANY;
307 profiles.push_back(profile); 307 profiles.push_back(profile);
308 break; 308 break;
309 case V4L2_PIX_FMT_VP9: 309 case V4L2_PIX_FMT_VP9:
310 profile.profile = media::VP9PROFILE_ANY; 310 profile.profile = media::VP9PROFILE_PROFILE0;
311 profiles.push_back(profile);
312 profile.profile = media::VP9PROFILE_PROFILE1;
313 profiles.push_back(profile);
314 profile.profile = media::VP9PROFILE_PROFILE2;
315 profiles.push_back(profile);
316 profile.profile = media::VP9PROFILE_PROFILE3;
311 profiles.push_back(profile); 317 profiles.push_back(profile);
312 break; 318 break;
313 } 319 }
314 } 320 }
315 321
316 return profiles; 322 return profiles;
317 } 323 }
318 324
319 void V4L2VideoEncodeAccelerator::FrameProcessed( 325 void V4L2VideoEncodeAccelerator::FrameProcessed(
320 bool force_keyframe, 326 bool force_keyframe,
(...skipping 856 matching lines...) Expand 10 before | Expand all | Expand 10 after
1177 reqbufs.count = 0; 1183 reqbufs.count = 0;
1178 reqbufs.type = V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE; 1184 reqbufs.type = V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE;
1179 reqbufs.memory = V4L2_MEMORY_MMAP; 1185 reqbufs.memory = V4L2_MEMORY_MMAP;
1180 IOCTL_OR_LOG_ERROR(VIDIOC_REQBUFS, &reqbufs); 1186 IOCTL_OR_LOG_ERROR(VIDIOC_REQBUFS, &reqbufs);
1181 1187
1182 output_buffer_map_.clear(); 1188 output_buffer_map_.clear();
1183 free_output_buffers_.clear(); 1189 free_output_buffers_.clear();
1184 } 1190 }
1185 1191
1186 } // namespace content 1192 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/media/gpu_video_accelerator_util.cc ('k') | content/common/gpu/media/vaapi_wrapper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698