| 2115 | } |
| 2116 | |
| 2117 | static BenchmarkResult MakeCpuCompositeResult(const BenchmarkOptions& options, const QImage& overlay_image, |
| 2118 | const std::string& name, DecodeKind decode_kind, |
| 2119 | const std::string& decode_label) { |
| 2120 | BenchmarkResult result; |
| 2121 | result.name = name; |
| 2122 | result.decode_backend = decode_label; |
| 2123 | result.composite_backend = "QPainter CPU"; |
| 2124 | result.hw_decode_requested = decode_kind != DecodeKind::Software; |
| 2125 | result.readback_to_cpu = decode_kind != DecodeKind::Software; |
| 2126 | result.note = decode_kind == DecodeKind::Cuda |
| 2127 | ? "CUDA decode -> CPU readback -> QPainter" |
| 2128 | : decode_kind == DecodeKind::Vaapi |
| 2129 | ? "HW decode -> CPU readback -> QPainter" |
| 2130 | : decode_kind == DecodeKind::Vulkan |
| 2131 | ? "HW decode if available -> CPU readback -> QPainter" |
| 2132 | : "Software decode -> QPainter"; |
| 2133 | result.stats = RunCpuCompositeBenchmark(options, overlay_image, decode_kind, result.hw_decode_used); |
| 2134 | return result; |
| 2135 | } |
| 2136 | |
| 2137 | static BenchmarkResult MakeVulkanCompositeResult(const BenchmarkOptions& options, const QImage& overlay_image, |
| 2138 | const std::string& name, DecodeKind decode_kind, |
no test coverage detected