Commit 05ce6db9 authored by Daniel Cheng's avatar Daniel Cheng Committed by Commit Bot

Use built-in kMaxValue enumerator for VideoDecodeAccelerator::Recent.

Also use the two argument version of UMA_HISTOGRAM_ENUMERATION which
autodeduces the boundary value.

Bug: 742517
Change-Id: I41bb007b16869456baa16b5ab8753c1bd3e565cc
Reviewed-on: https://chromium-review.googlesource.com/989418Reviewed-by: default avatarLuis Hector Chavez <lhchavez@chromium.org>
Commit-Queue: Daniel Cheng <dcheng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#547470}
parent 756acd69
...@@ -88,7 +88,6 @@ interface VideoDecodeAccelerator { ...@@ -88,7 +88,6 @@ interface VideoDecodeAccelerator {
PLATFORM_FAILURE = 4, PLATFORM_FAILURE = 4,
INSUFFICIENT_RESOURCES = 5, INSUFFICIENT_RESOURCES = 5,
CANCELLED = 6, CANCELLED = 6,
RESULT_MAX = 7,
}; };
// Initializes video decoder accelerator with specific video codec profile. // Initializes video decoder accelerator with specific video codec profile.
......
...@@ -374,11 +374,8 @@ void GpuArcVideoDecodeAccelerator::Initialize( ...@@ -374,11 +374,8 @@ void GpuArcVideoDecodeAccelerator::Initialize(
auto result = InitializeTask(std::move(config)); auto result = InitializeTask(std::move(config));
// Report initialization status to UMA. // Report initialization status to UMA.
const int RESULT_MAX =
static_cast<int>(mojom::VideoDecodeAccelerator::Result::RESULT_MAX);
UMA_HISTOGRAM_ENUMERATION( UMA_HISTOGRAM_ENUMERATION(
"Media.GpuArcVideoDecodeAccelerator.InitializeResult", "Media.GpuArcVideoDecodeAccelerator.InitializeResult", result);
static_cast<int>(result), RESULT_MAX);
std::move(callback).Run(result); std::move(callback).Run(result);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment