mirror of
https://github.com/MobileGL-Dev/MobileGL
synced 2026-09-10 05:08:31 +09:00
[Fix] (Tools/TraceReplay): show window surface after first present
This commit is contained in:
@@ -22,6 +22,7 @@ void PrintUsage(const char *argv0) {
|
||||
<< " --height N Replay surface height override\n"
|
||||
<< " --window-surface Replay to a native window surface\n"
|
||||
<< " --pbuffer-surface Replay to an EGL pbuffer surface (default)\n"
|
||||
<< " --hold-ms N Keep the replay process alive after retrace (default: 0)\n"
|
||||
<< " --ssim-threshold N Minimum SSIM required to pass (default: 0.99)\n"
|
||||
<< " --crop-x N Compare crop x\n"
|
||||
<< " --crop-y N Compare crop y\n"
|
||||
@@ -100,6 +101,8 @@ bool ParseArgs(int argc, char **argv, mobilegl_trace::Request &request) {
|
||||
request.usePbuffer = false;
|
||||
} else if (arg == "--pbuffer-surface") {
|
||||
request.usePbuffer = true;
|
||||
} else if (arg == "--hold-ms") {
|
||||
if (!ReadInt(argc, argv, i, request.holdMs)) return false;
|
||||
} else if (arg == "--ssim-threshold") {
|
||||
if (!ReadDouble(argc, argv, i, request.ssimThreshold)) return false;
|
||||
} else if (arg == "--crop-x") {
|
||||
@@ -130,6 +133,10 @@ bool ParseArgs(int argc, char **argv, mobilegl_trace::Request &request) {
|
||||
std::cerr << "--target-call is required\n";
|
||||
return false;
|
||||
}
|
||||
if (request.holdMs < 0) {
|
||||
std::cerr << "--hold-ms must be non-negative\n";
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user