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

Issue 1896983004: Rename misleading |is_ambiguous| parameter

Created:
4 years, 8 months ago by ddorwin
Modified:
3 years, 11 months ago
Reviewers:
xhwang, DaleCurtis, kqyang
CC:
chromium-reviews, feature-media-reviews_chromium.org, hubbe, kqyang, servolk
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Rename misleading |is_ambiguous| parameter TEST=Existing MediaCanPlayTypeTests

Patch Set 1 #

Total comments: 24

Patch Set 2 : review feedback #

Patch Set 3 : rebase #

Patch Set 4 : update VP9 comment to match #

Total comments: 2

Patch Set 5 : fix comment: VP8 is still handled by the map #

Patch Set 6 : rename is_known_supported to is_probably_supported #

Patch Set 7 : Rebase on b36186ff03599c360e1c536f968aa7022105d3d0. #

Patch Set 8 : Update out of date comment #

Unified diffs Side-by-side diffs Delta from patch set Stats (+41 lines, -38 lines) Patch
M media/base/mime_util_internal.h View 1 2 3 4 5 6 1 chunk +22 lines, -17 lines 0 comments Download
M media/base/mime_util_internal.cc View 1 2 3 4 5 6 7 8 chunks +19 lines, -21 lines 0 comments Download

Messages

Total messages: 18 (6 generated)
ddorwin
Naming suggestions very welcome. I considered |is_confident...| and |is_likely_supported|. Note the inversion in the parameter's ...
4 years, 8 months ago (2016-04-18 23:43:37 UTC) #2
ddorwin
The only truly ambiguous codec strings now are those few in kAmbiguousCodecStringMap.
4 years, 8 months ago (2016-04-18 23:45:06 UTC) #3
ddorwin
On 2016/04/18 23:45:06, ddorwin wrote: > The only truly ambiguous codec strings now are those ...
4 years, 8 months ago (2016-04-19 00:34:14 UTC) #4
xhwang
Mostly nits and naming. https://chromiumcodereview.appspot.com/1896983004/diff/1/media/base/mime_util_internal.h File media/base/mime_util_internal.h (right): https://chromiumcodereview.appspot.com/1896983004/diff/1/media/base/mime_util_internal.h#newcode86 media/base/mime_util_internal.h:86: bool is_ambiguous; Do you want ...
4 years, 8 months ago (2016-04-19 23:59:43 UTC) #8
DaleCurtis
https://chromiumcodereview.appspot.com/1896983004/diff/1/media/base/mime_util_internal.h File media/base/mime_util_internal.h (right): https://chromiumcodereview.appspot.com/1896983004/diff/1/media/base/mime_util_internal.h#newcode101 media/base/mime_util_internal.h:101: // Returns IsSupported if all codec IDs in |codecs| ...
4 years, 8 months ago (2016-04-20 19:18:54 UTC) #9
ddorwin
PS2 addresses the feedback. PS3 (and PS4) rebases on top of https://codereview.chromium.org/1624703002/, including inverting the ...
4 years, 8 months ago (2016-04-21 00:50:30 UTC) #11
DaleCurtis
lgtm with the current wording.
4 years, 8 months ago (2016-04-21 00:53:02 UTC) #12
kqyang
https://chromiumcodereview.appspot.com/1896983004/diff/80001/media/base/mime_util_internal.cc File media/base/mime_util_internal.cc (right): https://chromiumcodereview.appspot.com/1896983004/diff/80001/media/base/mime_util_internal.cc#newcode36 media/base/mime_util_internal.cc:36: // vp8, vp8.0, vp9, vp9.0, and vp09.xx.xx.xx.xx.xx.xx.xx are handled ...
4 years, 8 months ago (2016-04-21 00:59:48 UTC) #14
ddorwin
https://chromiumcodereview.appspot.com/1896983004/diff/80001/media/base/mime_util_internal.cc File media/base/mime_util_internal.cc (right): https://chromiumcodereview.appspot.com/1896983004/diff/80001/media/base/mime_util_internal.cc#newcode36 media/base/mime_util_internal.cc:36: // vp8, vp8.0, vp9, vp9.0, and vp09.xx.xx.xx.xx.xx.xx.xx are handled ...
4 years, 8 months ago (2016-04-21 02:09:50 UTC) #15
xhwang
lgtm % potential naming change https://chromiumcodereview.appspot.com/1896983004/diff/1/media/base/mime_util_internal.h File media/base/mime_util_internal.h (right): https://chromiumcodereview.appspot.com/1896983004/diff/1/media/base/mime_util_internal.h#newcode102 media/base/mime_util_internal.h:102: // be supported, and ...
4 years, 8 months ago (2016-04-21 05:59:44 UTC) #16
ddorwin
I will rebase and land after https://codereview.chromium.org/1677133003/ lands. https://codereview.chromium.org/1896983004/diff/1/media/base/mime_util_internal.h File media/base/mime_util_internal.h (right): https://codereview.chromium.org/1896983004/diff/1/media/base/mime_util_internal.h#newcode122 media/base/mime_util_internal.h:122: bool* ...
4 years, 8 months ago (2016-04-21 17:30:48 UTC) #17
ddorwin
4 years, 8 months ago (2016-04-21 19:10:09 UTC) #18
StringToCodec() is a bit confusing and inconsistent with respect to proprietary
codecs. For both those in string_to_codec_map_ and H.264, we always identify the
codec and return true regardless of whether proprietary codecs are enabled. (For
HEVC, we don't parse at all.) We then rely on a subsequent call to
IsCodecSupported to reject proprietary codecs.

This was a bit strange but perhaps fine until we added an assertive statement:
|is_probably_supported|.

Thoughts? Should we revert to a negative meaning, such as
|support_cannot_be_determined|? Even then, it seems a bit misleading to imply
"maybe this proprietary codec is supported" when we know it's not.

Really, we should make these decisions outside the string conversion function,
but then we'd have to expose more output parameters and/or callback(s). (This is
something we may need to do in order to detect profiles, etc., but that's
overkill for now.)

https://codereview.chromium.org/1896983004/diff/1/media/base/mime_util_intern...
File media/base/mime_util_internal.cc (left):

https://codereview.chromium.org/1896983004/diff/1/media/base/mime_util_intern...
media/base/mime_util_internal.cc:170: // TODO(servolk): Most HEVC codec ids are
treated as ambiguous (see above),
On 2016/04/18 23:43:37, ddorwin wrote:
> This should have been removed in https://codereview.chromium.org/1864743002/.

But, it was still affecting the output, which these tests were catching on Cast.
This is moot now that https://codereview.chromium.org/1677133003 has landed.

Powered by Google App Engine
This is Rietveld 408576698