mirror of
https://github.com/Genymobile/scrcpy.git
synced 2025-04-20 19:45:00 +00:00
Adding codecProfile to server options
(cherry picked from commit d4fb6a0c19af23d0d3c57721f6ccc91e4fad67f3)
This commit is contained in:
parent
d93cf8420b
commit
e7f205ca19
2 changed files with 14 additions and 2 deletions
|
@ -10,6 +10,7 @@ public class Options {
|
|||
private Rect crop;
|
||||
private boolean sendFrameMeta; // send PTS so that the client may record properly
|
||||
private boolean control;
|
||||
private int codecProfile;
|
||||
|
||||
public int getMaxSize() {
|
||||
return maxSize;
|
||||
|
@ -66,4 +67,12 @@ public class Options {
|
|||
public void setControl(boolean control) {
|
||||
this.control = control;
|
||||
}
|
||||
|
||||
public int getCodecProfile() {
|
||||
return codecProfile;
|
||||
}
|
||||
|
||||
public void setCodecProfile(int codecProfile) {
|
||||
this.codecProfile = codecProfile;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -79,8 +79,8 @@ public final class Server {
|
|||
"The server version (" + clientVersion + ") does not match the client " + "(" + BuildConfig.VERSION_NAME + ")");
|
||||
}
|
||||
|
||||
if (args.length != 8) {
|
||||
throw new IllegalArgumentException("Expecting 8 parameters");
|
||||
if (args.length != 9) {
|
||||
throw new IllegalArgumentException("Expecting 9 parameters");
|
||||
}
|
||||
|
||||
Options options = new Options();
|
||||
|
@ -107,6 +107,9 @@ public final class Server {
|
|||
boolean control = Boolean.parseBoolean(args[7]);
|
||||
options.setControl(control);
|
||||
|
||||
int codecProfile = Integer.parseInt(args[8]);
|
||||
options.setCodecProfile(codecProfile);
|
||||
|
||||
return options;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue