Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
SDK
/
exoplayer
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
09df3a01
authored
Nov 18, 2019
by
olly
Committed by
Oliver Woodman
Nov 19, 2019
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Don't check rotated resolution for HEVC on LG Q7
Issue: #6612 PiperOrigin-RevId: 281048324
parent
8c848a2a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
3 deletions
library/core/src/main/java/com/google/android/exoplayer2/mediacodec/MediaCodecInfo.java
library/core/src/main/java/com/google/android/exoplayer2/mediacodec/MediaCodecInfo.java
View file @
09df3a01
...
...
@@ -405,10 +405,8 @@ public final class MediaCodecInfo {
return
false
;
}
if
(!
areSizeAndRateSupportedV21
(
videoCapabilities
,
width
,
height
,
frameRate
))
{
// Capabilities are known to be inaccurately reported for vertical resolutions on some devices
// (b/31387661). If the video is vertical and the capabilities indicate support if the width
// and height are swapped, we assume that the vertical resolution is also supported.
if
(
width
>=
height
||
!
enableRotatedVerticalResolutionWorkaround
(
name
)
||
!
areSizeAndRateSupportedV21
(
videoCapabilities
,
height
,
width
,
frameRate
))
{
logNoSupport
(
"sizeAndRate.support, "
+
width
+
"x"
+
height
+
"x"
+
frameRate
);
return
false
;
...
...
@@ -599,4 +597,21 @@ public final class MediaCodecInfo {
private
static
int
getMaxSupportedInstancesV23
(
CodecCapabilities
capabilities
)
{
return
capabilities
.
getMaxSupportedInstances
();
}
/**
* Capabilities are known to be inaccurately reported for vertical resolutions on some devices.
* [Internal ref: b/31387661]. When this workaround is enabled, we also check whether the
* capabilities indicate support if the width and height are swapped. If they do, we assume that
* the vertical resolution is also supported.
*
* @param name The name of the codec.
* @return Whether to enable the workaround.
*/
private
static
final
boolean
enableRotatedVerticalResolutionWorkaround
(
String
name
)
{
if
(
"OMX.MTK.VIDEO.DECODER.HEVC"
.
equals
(
name
)
&&
"mcv5a"
.
equals
(
Util
.
DEVICE
))
{
// See https://github.com/google/ExoPlayer/issues/6612.
return
false
;
}
return
true
;
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment