Fix incorrect scale on back camera in reverse landscape (#1559)

Co-authored-by: bemusementpark <bemusementpark>
This commit is contained in:
Andrew 2024-07-22 13:58:12 +09:30 committed by GitHub
parent bb239a4048
commit bc968dcdae
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -14,7 +14,7 @@ class RemoteRotationVideoProxySink: VideoSink {
val thisSink = targetSink ?: return
val thisFrame = frame ?: return
val modifiedRotation = thisFrame.rotation - rotation
val modifiedRotation = (thisFrame.rotation - rotation + 360) % 360
val newFrame = VideoFrame(thisFrame.buffer, modifiedRotation, thisFrame.timestampNs)
thisSink.onFrame(newFrame)