mirror of
https://github.com/Genymobile/scrcpy.git
synced 2025-04-20 11:35:57 +00:00
fix:Add Support For Meizu Phone
Fix the error case by flyme nightMode. issue #1
This commit is contained in:
parent
1c1fe5ec53
commit
b0f78edaca
1 changed files with 2 additions and 0 deletions
|
@ -8,6 +8,7 @@ import android.media.MediaCodec;
|
|||
import android.media.MediaCodecInfo;
|
||||
import android.media.MediaFormat;
|
||||
import android.os.IBinder;
|
||||
import android.os.Looper;
|
||||
import android.view.Surface;
|
||||
|
||||
import java.io.FileDescriptor;
|
||||
|
@ -66,6 +67,7 @@ public class ScreenEncoder implements Device.RotationListener {
|
|||
Rect videoRect = device.getScreenInfo().getVideoSize().toRect();
|
||||
setSize(format, videoRect.width(), videoRect.height());
|
||||
configure(codec, format);
|
||||
Looper.prepare();
|
||||
Surface surface = codec.createInputSurface();
|
||||
setDisplaySurface(display, surface, contentRect, videoRect);
|
||||
codec.start();
|
||||
|
|
Loading…
Add table
Reference in a new issue