mirror of
https://github.com/Genymobile/scrcpy
synced 2025-08-31 14:25:56 +00:00
Add support for H265
Add option --codec=h265. PR #3713 <https://github.com/Genymobile/scrcpy/pull/3713> Fixes #3092 <https://github.com/Genymobile/scrcpy/issues/3092>
This commit is contained in:
@@ -110,7 +110,7 @@ static const struct sc_option options[] = {
|
||||
.longopt_id = OPT_CODEC,
|
||||
.longopt = "codec",
|
||||
.argdesc = "name",
|
||||
.text = "Select a video codec (h264).",
|
||||
.text = "Select a video codec (h264 or h265).",
|
||||
},
|
||||
{
|
||||
.longopt_id = OPT_CODEC_OPTIONS,
|
||||
@@ -1390,7 +1390,11 @@ parse_codec(const char *optarg, enum sc_codec *codec) {
|
||||
*codec = SC_CODEC_H264;
|
||||
return true;
|
||||
}
|
||||
LOGE("Unsupported codec: %s (expected h264)", optarg);
|
||||
if (!strcmp(optarg, "h265")) {
|
||||
*codec = SC_CODEC_H265;
|
||||
return true;
|
||||
}
|
||||
LOGE("Unsupported codec: %s (expected h264 or h265)", optarg);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user