Add mIgnoreTransform handling for SurfaceTextureHost with WebRender
Categories
(Core :: Graphics: WebRender, enhancement, P3)
Tracking
()
People
(Reporter: sotaro, Assigned: sotaro)
References
(Blocks 1 open bug)
Details
This bug is created by Bug 1499255 Comment 8.
Assignee | ||
Updated•6 years ago
|
Updated•6 years ago
|
Assignee | ||
Comment 1•5 years ago
•
|
||
SurfaceTexture is expected to be used with SurfaceTexture.getTransformMatrix(). With the matrix, SurfaceTexture's gl texture worked as bottom left origin. But current WebRender does not use the getTransformMatrix(). Then the gl texture worked as top left origin.
In android, GLConsumer::computeTransformMatrix() calculate a matrix for the getTransformMatrix(). If there is no transform, it jut multiply y-flip.
http://androidxref.com/9.0.0_r3/xref/frameworks/native/libs/gui/GLConsumer.cpp#866
https://developer.android.com/reference/android/graphics/SurfaceTexture
Assignee | ||
Comment 2•5 years ago
|
||
On WebRender, the getTransformMatrix() is not handled yet. Then it worked as mIgnoreTransform == true.
Assignee | ||
Comment 3•5 years ago
|
||
On android, SurfaceTextureImage is created as gl::OriginPos::BottomLeft, though it is not handled by WebRender yet.
https://searchfox.org/mozilla-central/source/dom/media/platforms/android/RemoteDataDecoder.cpp#283
Assignee | ||
Comment 4•5 years ago
|
||
On android, SurfaceTexture is used only for video decoding and WebGL, if android frameworks as expected, it seems not necessary to handle getTransformMatrix().
But if we use SurfaceTexture for camera frame rendering, it might cause the problem. Further, there might be a device that change rotation at ANativeWindow side.
Assignee | ||
Updated•5 years ago
|
Comment 5•4 years ago
|
||
@sotaro: What issues is this currently causing? Or is this a performance issue?
Assignee | ||
Comment 6•4 years ago
•
|
||
For now, we do not have a issue by it. Then we could close this bug for now. When the problem happens, this bug could be re-opened.
This is not a performance issue. When transform is set by android platform, image is just rendered as rotated.
Description
•