diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/debugger/gdbstub.cpp | 50 | ||||
| -rw-r--r-- | src/core/hle/service/hid/irs.cpp | 249 | ||||
| -rw-r--r-- | src/core/hle/service/hid/irs.h | 232 | ||||
| -rw-r--r-- | src/video_core/engines/maxwell_3d.cpp | 4 | ||||
| -rw-r--r-- | src/video_core/engines/maxwell_3d.h | 2 |
5 files changed, 491 insertions, 46 deletions
diff --git a/src/core/debugger/gdbstub.cpp b/src/core/debugger/gdbstub.cpp index 682651a86..f52d78829 100644 --- a/src/core/debugger/gdbstub.cpp +++ b/src/core/debugger/gdbstub.cpp | |||
| @@ -422,6 +422,18 @@ static std::string GetThreadState(const Kernel::KThread* thread) { | |||
| 422 | } | 422 | } |
| 423 | } | 423 | } |
| 424 | 424 | ||
| 425 | static std::string PaginateBuffer(std::string_view buffer, std::string_view request) { | ||
| 426 | const auto amount{request.substr(request.find(',') + 1)}; | ||
| 427 | const auto offset_val{static_cast<u64>(strtoll(request.data(), nullptr, 16))}; | ||
| 428 | const auto amount_val{static_cast<u64>(strtoll(amount.data(), nullptr, 16))}; | ||
| 429 | |||
| 430 | if (offset_val + amount_val > buffer.size()) { | ||
| 431 | return fmt::format("l{}", buffer.substr(offset_val)); | ||
| 432 | } else { | ||
| 433 | return fmt::format("m{}", buffer.substr(offset_val, amount_val)); | ||
| 434 | } | ||
| 435 | } | ||
| 436 | |||
| 425 | void GDBStub::HandleQuery(std::string_view command) { | 437 | void GDBStub::HandleQuery(std::string_view command) { |
| 426 | if (command.starts_with("TStatus")) { | 438 | if (command.starts_with("TStatus")) { |
| 427 | // no tracepoint support | 439 | // no tracepoint support |
| @@ -430,18 +442,8 @@ void GDBStub::HandleQuery(std::string_view command) { | |||
| 430 | SendReply("PacketSize=4000;qXfer:features:read+;qXfer:threads:read+;qXfer:libraries:read+;" | 442 | SendReply("PacketSize=4000;qXfer:features:read+;qXfer:threads:read+;qXfer:libraries:read+;" |
| 431 | "vContSupported+;QStartNoAckMode+"); | 443 | "vContSupported+;QStartNoAckMode+"); |
| 432 | } else if (command.starts_with("Xfer:features:read:target.xml:")) { | 444 | } else if (command.starts_with("Xfer:features:read:target.xml:")) { |
| 433 | const auto offset{command.substr(30)}; | ||
| 434 | const auto amount{command.substr(command.find(',') + 1)}; | ||
| 435 | |||
| 436 | const auto offset_val{static_cast<u64>(strtoll(offset.data(), nullptr, 16))}; | ||
| 437 | const auto amount_val{static_cast<u64>(strtoll(amount.data(), nullptr, 16))}; | ||
| 438 | const auto target_xml{arch->GetTargetXML()}; | 445 | const auto target_xml{arch->GetTargetXML()}; |
| 439 | 446 | SendReply(PaginateBuffer(target_xml, command.substr(30))); | |
| 440 | if (offset_val + amount_val > target_xml.size()) { | ||
| 441 | SendReply("l" + target_xml.substr(offset_val)); | ||
| 442 | } else { | ||
| 443 | SendReply("m" + target_xml.substr(offset_val, amount_val)); | ||
| 444 | } | ||
| 445 | } else if (command.starts_with("Offsets")) { | 447 | } else if (command.starts_with("Offsets")) { |
| 446 | Loader::AppLoader::Modules modules; | 448 | Loader::AppLoader::Modules modules; |
| 447 | system.GetAppLoader().ReadNSOModules(modules); | 449 | system.GetAppLoader().ReadNSOModules(modules); |
| @@ -454,6 +456,20 @@ void GDBStub::HandleQuery(std::string_view command) { | |||
| 454 | SendReply(fmt::format("TextSeg={:x}", | 456 | SendReply(fmt::format("TextSeg={:x}", |
| 455 | system.CurrentProcess()->PageTable().GetCodeRegionStart())); | 457 | system.CurrentProcess()->PageTable().GetCodeRegionStart())); |
| 456 | } | 458 | } |
| 459 | } else if (command.starts_with("Xfer:libraries:read::")) { | ||
| 460 | Loader::AppLoader::Modules modules; | ||
| 461 | system.GetAppLoader().ReadNSOModules(modules); | ||
| 462 | |||
| 463 | std::string buffer; | ||
| 464 | buffer += R"(<?xml version="1.0"?>)"; | ||
| 465 | buffer += "<library-list>"; | ||
| 466 | for (const auto& [base, name] : modules) { | ||
| 467 | buffer += fmt::format(R"(<library name="{}"><segment address="{:#x}"/></library>)", | ||
| 468 | EscapeXML(name), base); | ||
| 469 | } | ||
| 470 | buffer += "</library-list>"; | ||
| 471 | |||
| 472 | SendReply(PaginateBuffer(buffer, command.substr(21))); | ||
| 457 | } else if (command.starts_with("fThreadInfo")) { | 473 | } else if (command.starts_with("fThreadInfo")) { |
| 458 | // beginning of list | 474 | // beginning of list |
| 459 | const auto& threads = system.GlobalSchedulerContext().GetThreadList(); | 475 | const auto& threads = system.GlobalSchedulerContext().GetThreadList(); |
| @@ -484,17 +500,7 @@ void GDBStub::HandleQuery(std::string_view command) { | |||
| 484 | 500 | ||
| 485 | buffer += "</threads>"; | 501 | buffer += "</threads>"; |
| 486 | 502 | ||
| 487 | const auto offset{command.substr(19)}; | 503 | SendReply(PaginateBuffer(buffer, command.substr(19))); |
| 488 | const auto amount{command.substr(command.find(',') + 1)}; | ||
| 489 | |||
| 490 | const auto offset_val{static_cast<u64>(strtoll(offset.data(), nullptr, 16))}; | ||
| 491 | const auto amount_val{static_cast<u64>(strtoll(amount.data(), nullptr, 16))}; | ||
| 492 | |||
| 493 | if (offset_val + amount_val > buffer.size()) { | ||
| 494 | SendReply("l" + buffer.substr(offset_val)); | ||
| 495 | } else { | ||
| 496 | SendReply("m" + buffer.substr(offset_val, amount_val)); | ||
| 497 | } | ||
| 498 | } else if (command.starts_with("Attached")) { | 504 | } else if (command.starts_with("Attached")) { |
| 499 | SendReply("0"); | 505 | SendReply("0"); |
| 500 | } else if (command.starts_with("StartNoAckMode")) { | 506 | } else if (command.starts_with("StartNoAckMode")) { |
diff --git a/src/core/hle/service/hid/irs.cpp b/src/core/hle/service/hid/irs.cpp index 9e32f3e60..d2a91d913 100644 --- a/src/core/hle/service/hid/irs.cpp +++ b/src/core/hle/service/hid/irs.cpp | |||
| @@ -5,7 +5,9 @@ | |||
| 5 | #include "core/core_timing.h" | 5 | #include "core/core_timing.h" |
| 6 | #include "core/hle/ipc_helpers.h" | 6 | #include "core/hle/ipc_helpers.h" |
| 7 | #include "core/hle/kernel/k_shared_memory.h" | 7 | #include "core/hle/kernel/k_shared_memory.h" |
| 8 | #include "core/hle/kernel/k_transfer_memory.h" | ||
| 8 | #include "core/hle/kernel/kernel.h" | 9 | #include "core/hle/kernel/kernel.h" |
| 10 | #include "core/hle/service/hid/errors.h" | ||
| 9 | #include "core/hle/service/hid/irs.h" | 11 | #include "core/hle/service/hid/irs.h" |
| 10 | 12 | ||
| 11 | namespace Service::HID { | 13 | namespace Service::HID { |
| @@ -38,21 +40,32 @@ IRS::IRS(Core::System& system_) : ServiceFramework{system_, "irs"} { | |||
| 38 | } | 40 | } |
| 39 | 41 | ||
| 40 | void IRS::ActivateIrsensor(Kernel::HLERequestContext& ctx) { | 42 | void IRS::ActivateIrsensor(Kernel::HLERequestContext& ctx) { |
| 41 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 43 | IPC::RequestParser rp{ctx}; |
| 44 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 45 | |||
| 46 | LOG_WARNING(Service_HID, "(STUBBED) called, applet_resource_user_id={}", | ||
| 47 | applet_resource_user_id); | ||
| 42 | 48 | ||
| 43 | IPC::ResponseBuilder rb{ctx, 2}; | 49 | IPC::ResponseBuilder rb{ctx, 2}; |
| 44 | rb.Push(ResultSuccess); | 50 | rb.Push(ResultSuccess); |
| 45 | } | 51 | } |
| 46 | 52 | ||
| 47 | void IRS::DeactivateIrsensor(Kernel::HLERequestContext& ctx) { | 53 | void IRS::DeactivateIrsensor(Kernel::HLERequestContext& ctx) { |
| 48 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 54 | IPC::RequestParser rp{ctx}; |
| 55 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 56 | |||
| 57 | LOG_WARNING(Service_HID, "(STUBBED) called, applet_resource_user_id={}", | ||
| 58 | applet_resource_user_id); | ||
| 49 | 59 | ||
| 50 | IPC::ResponseBuilder rb{ctx, 2}; | 60 | IPC::ResponseBuilder rb{ctx, 2}; |
| 51 | rb.Push(ResultSuccess); | 61 | rb.Push(ResultSuccess); |
| 52 | } | 62 | } |
| 53 | 63 | ||
| 54 | void IRS::GetIrsensorSharedMemoryHandle(Kernel::HLERequestContext& ctx) { | 64 | void IRS::GetIrsensorSharedMemoryHandle(Kernel::HLERequestContext& ctx) { |
| 55 | LOG_DEBUG(Service_IRS, "called"); | 65 | IPC::RequestParser rp{ctx}; |
| 66 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 67 | |||
| 68 | LOG_DEBUG(Service_IRS, "called, applet_resource_user_id={}", applet_resource_user_id); | ||
| 56 | 69 | ||
| 57 | IPC::ResponseBuilder rb{ctx, 2, 1}; | 70 | IPC::ResponseBuilder rb{ctx, 2, 1}; |
| 58 | rb.Push(ResultSuccess); | 71 | rb.Push(ResultSuccess); |
| @@ -60,35 +73,109 @@ void IRS::GetIrsensorSharedMemoryHandle(Kernel::HLERequestContext& ctx) { | |||
| 60 | } | 73 | } |
| 61 | 74 | ||
| 62 | void IRS::StopImageProcessor(Kernel::HLERequestContext& ctx) { | 75 | void IRS::StopImageProcessor(Kernel::HLERequestContext& ctx) { |
| 63 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 76 | IPC::RequestParser rp{ctx}; |
| 77 | struct Parameters { | ||
| 78 | IrCameraHandle camera_handle; | ||
| 79 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 80 | u64 applet_resource_user_id; | ||
| 81 | }; | ||
| 82 | static_assert(sizeof(Parameters) == 0x10, "Parameters has incorrect size."); | ||
| 83 | |||
| 84 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 85 | |||
| 86 | LOG_WARNING(Service_IRS, | ||
| 87 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 88 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 89 | parameters.applet_resource_user_id); | ||
| 64 | 90 | ||
| 65 | IPC::ResponseBuilder rb{ctx, 2}; | 91 | IPC::ResponseBuilder rb{ctx, 2}; |
| 66 | rb.Push(ResultSuccess); | 92 | rb.Push(ResultSuccess); |
| 67 | } | 93 | } |
| 68 | 94 | ||
| 69 | void IRS::RunMomentProcessor(Kernel::HLERequestContext& ctx) { | 95 | void IRS::RunMomentProcessor(Kernel::HLERequestContext& ctx) { |
| 70 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 96 | IPC::RequestParser rp{ctx}; |
| 97 | struct Parameters { | ||
| 98 | IrCameraHandle camera_handle; | ||
| 99 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 100 | u64 applet_resource_user_id; | ||
| 101 | PackedMomentProcessorConfig processor_config; | ||
| 102 | }; | ||
| 103 | static_assert(sizeof(Parameters) == 0x30, "Parameters has incorrect size."); | ||
| 104 | |||
| 105 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 106 | |||
| 107 | LOG_WARNING(Service_IRS, | ||
| 108 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 109 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 110 | parameters.applet_resource_user_id); | ||
| 71 | 111 | ||
| 72 | IPC::ResponseBuilder rb{ctx, 2}; | 112 | IPC::ResponseBuilder rb{ctx, 2}; |
| 73 | rb.Push(ResultSuccess); | 113 | rb.Push(ResultSuccess); |
| 74 | } | 114 | } |
| 75 | 115 | ||
| 76 | void IRS::RunClusteringProcessor(Kernel::HLERequestContext& ctx) { | 116 | void IRS::RunClusteringProcessor(Kernel::HLERequestContext& ctx) { |
| 77 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 117 | IPC::RequestParser rp{ctx}; |
| 118 | struct Parameters { | ||
| 119 | IrCameraHandle camera_handle; | ||
| 120 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 121 | u64 applet_resource_user_id; | ||
| 122 | PackedClusteringProcessorConfig processor_config; | ||
| 123 | }; | ||
| 124 | static_assert(sizeof(Parameters) == 0x40, "Parameters has incorrect size."); | ||
| 125 | |||
| 126 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 127 | |||
| 128 | LOG_WARNING(Service_IRS, | ||
| 129 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 130 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 131 | parameters.applet_resource_user_id); | ||
| 78 | 132 | ||
| 79 | IPC::ResponseBuilder rb{ctx, 2}; | 133 | IPC::ResponseBuilder rb{ctx, 2}; |
| 80 | rb.Push(ResultSuccess); | 134 | rb.Push(ResultSuccess); |
| 81 | } | 135 | } |
| 82 | 136 | ||
| 83 | void IRS::RunImageTransferProcessor(Kernel::HLERequestContext& ctx) { | 137 | void IRS::RunImageTransferProcessor(Kernel::HLERequestContext& ctx) { |
| 84 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 138 | IPC::RequestParser rp{ctx}; |
| 139 | struct Parameters { | ||
| 140 | IrCameraHandle camera_handle; | ||
| 141 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 142 | u64 applet_resource_user_id; | ||
| 143 | PackedImageTransferProcessorConfig processor_config; | ||
| 144 | u32 transfer_memory_size; | ||
| 145 | }; | ||
| 146 | static_assert(sizeof(Parameters) == 0x30, "Parameters has incorrect size."); | ||
| 147 | |||
| 148 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 149 | const auto t_mem_handle{ctx.GetCopyHandle(0)}; | ||
| 150 | |||
| 151 | auto t_mem = | ||
| 152 | system.CurrentProcess()->GetHandleTable().GetObject<Kernel::KTransferMemory>(t_mem_handle); | ||
| 153 | |||
| 154 | LOG_WARNING(Service_IRS, | ||
| 155 | "(STUBBED) called, npad_type={}, npad_id={}, transfer_memory_size={}, " | ||
| 156 | "applet_resource_user_id={}", | ||
| 157 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 158 | parameters.transfer_memory_size, parameters.applet_resource_user_id); | ||
| 85 | 159 | ||
| 86 | IPC::ResponseBuilder rb{ctx, 2}; | 160 | IPC::ResponseBuilder rb{ctx, 2}; |
| 87 | rb.Push(ResultSuccess); | 161 | rb.Push(ResultSuccess); |
| 88 | } | 162 | } |
| 89 | 163 | ||
| 90 | void IRS::GetImageTransferProcessorState(Kernel::HLERequestContext& ctx) { | 164 | void IRS::GetImageTransferProcessorState(Kernel::HLERequestContext& ctx) { |
| 91 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 165 | IPC::RequestParser rp{ctx}; |
| 166 | struct Parameters { | ||
| 167 | IrCameraHandle camera_handle; | ||
| 168 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 169 | u64 applet_resource_user_id; | ||
| 170 | }; | ||
| 171 | static_assert(sizeof(Parameters) == 0x10, "Parameters has incorrect size."); | ||
| 172 | |||
| 173 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 174 | |||
| 175 | LOG_WARNING(Service_IRS, | ||
| 176 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 177 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 178 | parameters.applet_resource_user_id); | ||
| 92 | 179 | ||
| 93 | IPC::ResponseBuilder rb{ctx, 5}; | 180 | IPC::ResponseBuilder rb{ctx, 5}; |
| 94 | rb.Push(ResultSuccess); | 181 | rb.Push(ResultSuccess); |
| @@ -97,71 +184,195 @@ void IRS::GetImageTransferProcessorState(Kernel::HLERequestContext& ctx) { | |||
| 97 | } | 184 | } |
| 98 | 185 | ||
| 99 | void IRS::RunTeraPluginProcessor(Kernel::HLERequestContext& ctx) { | 186 | void IRS::RunTeraPluginProcessor(Kernel::HLERequestContext& ctx) { |
| 100 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 187 | IPC::RequestParser rp{ctx}; |
| 188 | const auto camera_handle{rp.PopRaw<IrCameraHandle>()}; | ||
| 189 | const auto processor_config{rp.PopRaw<PackedTeraPluginProcessorConfig>()}; | ||
| 190 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 191 | |||
| 192 | LOG_WARNING(Service_IRS, | ||
| 193 | "(STUBBED) called, npad_type={}, npad_id={}, mode={}, mcu_version={}.{}, " | ||
| 194 | "applet_resource_user_id={}", | ||
| 195 | camera_handle.npad_type, camera_handle.npad_id, processor_config.mode, | ||
| 196 | processor_config.required_mcu_version.major, | ||
| 197 | processor_config.required_mcu_version.minor, applet_resource_user_id); | ||
| 101 | 198 | ||
| 102 | IPC::ResponseBuilder rb{ctx, 2}; | 199 | IPC::ResponseBuilder rb{ctx, 2}; |
| 103 | rb.Push(ResultSuccess); | 200 | rb.Push(ResultSuccess); |
| 104 | } | 201 | } |
| 105 | 202 | ||
| 106 | void IRS::GetNpadIrCameraHandle(Kernel::HLERequestContext& ctx) { | 203 | void IRS::GetNpadIrCameraHandle(Kernel::HLERequestContext& ctx) { |
| 107 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 204 | IPC::RequestParser rp{ctx}; |
| 205 | const auto npad_id{rp.PopEnum<Core::HID::NpadIdType>()}; | ||
| 206 | |||
| 207 | if (npad_id > Core::HID::NpadIdType::Player8 && npad_id != Core::HID::NpadIdType::Invalid && | ||
| 208 | npad_id != Core::HID::NpadIdType::Handheld) { | ||
| 209 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 210 | rb.Push(InvalidNpadId); | ||
| 211 | return; | ||
| 212 | } | ||
| 213 | |||
| 214 | IrCameraHandle camera_handle{ | ||
| 215 | .npad_id = static_cast<u8>(NpadIdTypeToIndex(npad_id)), | ||
| 216 | .npad_type = Core::HID::NpadStyleIndex::None, | ||
| 217 | }; | ||
| 218 | |||
| 219 | LOG_WARNING(Service_IRS, "(STUBBED) called, npad_id={}, camera_npad_id={}, camera_npad_type={}", | ||
| 220 | npad_id, camera_handle.npad_id, camera_handle.npad_type); | ||
| 108 | 221 | ||
| 109 | IPC::ResponseBuilder rb{ctx, 3}; | 222 | IPC::ResponseBuilder rb{ctx, 3}; |
| 110 | rb.Push(ResultSuccess); | 223 | rb.Push(ResultSuccess); |
| 111 | rb.PushRaw<u32>(device_handle); | 224 | rb.PushRaw(camera_handle); |
| 112 | } | 225 | } |
| 113 | 226 | ||
| 114 | void IRS::RunPointingProcessor(Kernel::HLERequestContext& ctx) { | 227 | void IRS::RunPointingProcessor(Kernel::HLERequestContext& ctx) { |
| 115 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 228 | IPC::RequestParser rp{ctx}; |
| 229 | const auto camera_handle{rp.PopRaw<IrCameraHandle>()}; | ||
| 230 | const auto processor_config{rp.PopRaw<PackedPointingProcessorConfig>()}; | ||
| 231 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 232 | |||
| 233 | LOG_WARNING( | ||
| 234 | Service_IRS, | ||
| 235 | "(STUBBED) called, npad_type={}, npad_id={}, mcu_version={}.{}, applet_resource_user_id={}", | ||
| 236 | camera_handle.npad_type, camera_handle.npad_id, processor_config.required_mcu_version.major, | ||
| 237 | processor_config.required_mcu_version.minor, applet_resource_user_id); | ||
| 116 | 238 | ||
| 117 | IPC::ResponseBuilder rb{ctx, 2}; | 239 | IPC::ResponseBuilder rb{ctx, 2}; |
| 118 | rb.Push(ResultSuccess); | 240 | rb.Push(ResultSuccess); |
| 119 | } | 241 | } |
| 120 | 242 | ||
| 121 | void IRS::SuspendImageProcessor(Kernel::HLERequestContext& ctx) { | 243 | void IRS::SuspendImageProcessor(Kernel::HLERequestContext& ctx) { |
| 122 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 244 | IPC::RequestParser rp{ctx}; |
| 245 | struct Parameters { | ||
| 246 | IrCameraHandle camera_handle; | ||
| 247 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 248 | u64 applet_resource_user_id; | ||
| 249 | }; | ||
| 250 | static_assert(sizeof(Parameters) == 0x10, "Parameters has incorrect size."); | ||
| 251 | |||
| 252 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 253 | |||
| 254 | LOG_WARNING(Service_IRS, | ||
| 255 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 256 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 257 | parameters.applet_resource_user_id); | ||
| 123 | 258 | ||
| 124 | IPC::ResponseBuilder rb{ctx, 2}; | 259 | IPC::ResponseBuilder rb{ctx, 2}; |
| 125 | rb.Push(ResultSuccess); | 260 | rb.Push(ResultSuccess); |
| 126 | } | 261 | } |
| 127 | 262 | ||
| 128 | void IRS::CheckFirmwareVersion(Kernel::HLERequestContext& ctx) { | 263 | void IRS::CheckFirmwareVersion(Kernel::HLERequestContext& ctx) { |
| 129 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 264 | IPC::RequestParser rp{ctx}; |
| 265 | const auto camera_handle{rp.PopRaw<IrCameraHandle>()}; | ||
| 266 | const auto mcu_version{rp.PopRaw<PackedMcuVersion>()}; | ||
| 267 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 268 | |||
| 269 | LOG_WARNING( | ||
| 270 | Service_IRS, | ||
| 271 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}, mcu_version={}.{}", | ||
| 272 | camera_handle.npad_type, camera_handle.npad_id, applet_resource_user_id, mcu_version.major, | ||
| 273 | mcu_version.minor); | ||
| 130 | 274 | ||
| 131 | IPC::ResponseBuilder rb{ctx, 2}; | 275 | IPC::ResponseBuilder rb{ctx, 2}; |
| 132 | rb.Push(ResultSuccess); | 276 | rb.Push(ResultSuccess); |
| 133 | } | 277 | } |
| 134 | 278 | ||
| 135 | void IRS::SetFunctionLevel(Kernel::HLERequestContext& ctx) { | 279 | void IRS::SetFunctionLevel(Kernel::HLERequestContext& ctx) { |
| 136 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 280 | IPC::RequestParser rp{ctx}; |
| 281 | struct Parameters { | ||
| 282 | IrCameraHandle camera_handle; | ||
| 283 | PackedFunctionLevel function_level; | ||
| 284 | u64 applet_resource_user_id; | ||
| 285 | }; | ||
| 286 | static_assert(sizeof(Parameters) == 0x10, "Parameters has incorrect size."); | ||
| 287 | |||
| 288 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 289 | |||
| 290 | LOG_WARNING(Service_IRS, | ||
| 291 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 292 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 293 | parameters.applet_resource_user_id); | ||
| 137 | 294 | ||
| 138 | IPC::ResponseBuilder rb{ctx, 2}; | 295 | IPC::ResponseBuilder rb{ctx, 2}; |
| 139 | rb.Push(ResultSuccess); | 296 | rb.Push(ResultSuccess); |
| 140 | } | 297 | } |
| 141 | 298 | ||
| 142 | void IRS::RunImageTransferExProcessor(Kernel::HLERequestContext& ctx) { | 299 | void IRS::RunImageTransferExProcessor(Kernel::HLERequestContext& ctx) { |
| 143 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 300 | IPC::RequestParser rp{ctx}; |
| 301 | struct Parameters { | ||
| 302 | IrCameraHandle camera_handle; | ||
| 303 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 304 | u64 applet_resource_user_id; | ||
| 305 | PackedImageTransferProcessorExConfig processor_config; | ||
| 306 | u64 transfer_memory_size; | ||
| 307 | }; | ||
| 308 | static_assert(sizeof(Parameters) == 0x38, "Parameters has incorrect size."); | ||
| 309 | |||
| 310 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 311 | const auto t_mem_handle{ctx.GetCopyHandle(0)}; | ||
| 312 | |||
| 313 | auto t_mem = | ||
| 314 | system.CurrentProcess()->GetHandleTable().GetObject<Kernel::KTransferMemory>(t_mem_handle); | ||
| 315 | |||
| 316 | LOG_WARNING(Service_IRS, | ||
| 317 | "(STUBBED) called, npad_type={}, npad_id={}, transfer_memory_size={}, " | ||
| 318 | "applet_resource_user_id={}", | ||
| 319 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 320 | parameters.transfer_memory_size, parameters.applet_resource_user_id); | ||
| 144 | 321 | ||
| 145 | IPC::ResponseBuilder rb{ctx, 2}; | 322 | IPC::ResponseBuilder rb{ctx, 2}; |
| 146 | rb.Push(ResultSuccess); | 323 | rb.Push(ResultSuccess); |
| 147 | } | 324 | } |
| 148 | 325 | ||
| 149 | void IRS::RunIrLedProcessor(Kernel::HLERequestContext& ctx) { | 326 | void IRS::RunIrLedProcessor(Kernel::HLERequestContext& ctx) { |
| 150 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 327 | IPC::RequestParser rp{ctx}; |
| 328 | const auto camera_handle{rp.PopRaw<IrCameraHandle>()}; | ||
| 329 | const auto processor_config{rp.PopRaw<PackedIrLedProcessorConfig>()}; | ||
| 330 | const auto applet_resource_user_id{rp.Pop<u64>()}; | ||
| 331 | |||
| 332 | LOG_WARNING(Service_IRS, | ||
| 333 | "(STUBBED) called, npad_type={}, npad_id={}, light_target={}, mcu_version={}.{} " | ||
| 334 | "applet_resource_user_id={}", | ||
| 335 | camera_handle.npad_type, camera_handle.npad_id, processor_config.light_target, | ||
| 336 | processor_config.required_mcu_version.major, | ||
| 337 | processor_config.required_mcu_version.minor, applet_resource_user_id); | ||
| 151 | 338 | ||
| 152 | IPC::ResponseBuilder rb{ctx, 2}; | 339 | IPC::ResponseBuilder rb{ctx, 2}; |
| 153 | rb.Push(ResultSuccess); | 340 | rb.Push(ResultSuccess); |
| 154 | } | 341 | } |
| 155 | 342 | ||
| 156 | void IRS::StopImageProcessorAsync(Kernel::HLERequestContext& ctx) { | 343 | void IRS::StopImageProcessorAsync(Kernel::HLERequestContext& ctx) { |
| 157 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 344 | IPC::RequestParser rp{ctx}; |
| 345 | struct Parameters { | ||
| 346 | IrCameraHandle camera_handle; | ||
| 347 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 348 | u64 applet_resource_user_id; | ||
| 349 | }; | ||
| 350 | static_assert(sizeof(Parameters) == 0x10, "Parameters has incorrect size."); | ||
| 351 | |||
| 352 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 353 | |||
| 354 | LOG_WARNING(Service_IRS, | ||
| 355 | "(STUBBED) called, npad_type={}, npad_id={}, applet_resource_user_id={}", | ||
| 356 | parameters.camera_handle.npad_type, parameters.camera_handle.npad_id, | ||
| 357 | parameters.applet_resource_user_id); | ||
| 158 | 358 | ||
| 159 | IPC::ResponseBuilder rb{ctx, 2}; | 359 | IPC::ResponseBuilder rb{ctx, 2}; |
| 160 | rb.Push(ResultSuccess); | 360 | rb.Push(ResultSuccess); |
| 161 | } | 361 | } |
| 162 | 362 | ||
| 163 | void IRS::ActivateIrsensorWithFunctionLevel(Kernel::HLERequestContext& ctx) { | 363 | void IRS::ActivateIrsensorWithFunctionLevel(Kernel::HLERequestContext& ctx) { |
| 164 | LOG_WARNING(Service_IRS, "(STUBBED) called"); | 364 | IPC::RequestParser rp{ctx}; |
| 365 | struct Parameters { | ||
| 366 | PackedFunctionLevel function_level; | ||
| 367 | INSERT_PADDING_WORDS_NOINIT(1); | ||
| 368 | u64 applet_resource_user_id; | ||
| 369 | }; | ||
| 370 | static_assert(sizeof(Parameters) == 0x10, "Parameters has incorrect size."); | ||
| 371 | |||
| 372 | const auto parameters{rp.PopRaw<Parameters>()}; | ||
| 373 | |||
| 374 | LOG_WARNING(Service_IRS, "(STUBBED) called, function_level={}, applet_resource_user_id={}", | ||
| 375 | parameters.function_level.function_level, parameters.applet_resource_user_id); | ||
| 165 | 376 | ||
| 166 | IPC::ResponseBuilder rb{ctx, 2}; | 377 | IPC::ResponseBuilder rb{ctx, 2}; |
| 167 | rb.Push(ResultSuccess); | 378 | rb.Push(ResultSuccess); |
diff --git a/src/core/hle/service/hid/irs.h b/src/core/hle/service/hid/irs.h index efb29d3fd..361dc2213 100644 --- a/src/core/hle/service/hid/irs.h +++ b/src/core/hle/service/hid/irs.h | |||
| @@ -3,6 +3,7 @@ | |||
| 3 | 3 | ||
| 4 | #pragma once | 4 | #pragma once |
| 5 | 5 | ||
| 6 | #include "core/hid/hid_types.h" | ||
| 6 | #include "core/hle/service/service.h" | 7 | #include "core/hle/service/service.h" |
| 7 | 8 | ||
| 8 | namespace Core { | 9 | namespace Core { |
| @@ -17,6 +18,235 @@ public: | |||
| 17 | ~IRS() override; | 18 | ~IRS() override; |
| 18 | 19 | ||
| 19 | private: | 20 | private: |
| 21 | // This is nn::irsensor::IrCameraStatus | ||
| 22 | enum IrCameraStatus : u32 { | ||
| 23 | Available, | ||
| 24 | Unsupported, | ||
| 25 | Unconnected, | ||
| 26 | }; | ||
| 27 | |||
| 28 | // This is nn::irsensor::IrCameraInternalStatus | ||
| 29 | enum IrCameraInternalStatus : u32 { | ||
| 30 | Stopped, | ||
| 31 | FirmwareUpdateNeeded, | ||
| 32 | Unkown2, | ||
| 33 | Unkown3, | ||
| 34 | Unkown4, | ||
| 35 | FirmwareVersionRequested, | ||
| 36 | FirmwareVersionIsInvalid, | ||
| 37 | Ready, | ||
| 38 | Setting, | ||
| 39 | }; | ||
| 40 | |||
| 41 | // This is nn::irsensor::detail::StatusManager::IrSensorMode | ||
| 42 | enum IrSensorMode : u64 { | ||
| 43 | None, | ||
| 44 | MomentProcessor, | ||
| 45 | ClusteringProcessor, | ||
| 46 | ImageTransferProcessor, | ||
| 47 | PointingProcessorMarker, | ||
| 48 | TeraPluginProcessor, | ||
| 49 | IrLedProcessor, | ||
| 50 | }; | ||
| 51 | |||
| 52 | // This is nn::irsensor::ImageProcessorStatus | ||
| 53 | enum ImageProcessorStatus : u8 { | ||
| 54 | stopped, | ||
| 55 | running, | ||
| 56 | }; | ||
| 57 | |||
| 58 | // This is nn::irsensor::ImageTransferProcessorFormat | ||
| 59 | enum ImageTransferProcessorFormat : u8 { | ||
| 60 | Size320x240, | ||
| 61 | Size160x120, | ||
| 62 | Size80x60, | ||
| 63 | Size40x30, | ||
| 64 | Size20x15, | ||
| 65 | }; | ||
| 66 | |||
| 67 | // This is nn::irsensor::AdaptiveClusteringMode | ||
| 68 | enum AdaptiveClusteringMode : u8 { | ||
| 69 | StaticFov, | ||
| 70 | DynamicFov, | ||
| 71 | }; | ||
| 72 | |||
| 73 | // This is nn::irsensor::AdaptiveClusteringTargetDistance | ||
| 74 | enum AdaptiveClusteringTargetDistance : u8 { | ||
| 75 | Near, | ||
| 76 | Middle, | ||
| 77 | Far, | ||
| 78 | }; | ||
| 79 | |||
| 80 | // This is nn::irsensor::IrsHandAnalysisMode | ||
| 81 | enum IrsHandAnalysisMode : u8 { | ||
| 82 | Silhouette, | ||
| 83 | Image, | ||
| 84 | SilhoueteAndImage, | ||
| 85 | SilhuetteOnly, | ||
| 86 | }; | ||
| 87 | |||
| 88 | // This is nn::irsensor::IrSensorFunctionLevel | ||
| 89 | enum IrSensorFunctionLevel : u8 { | ||
| 90 | unknown0, | ||
| 91 | unknown1, | ||
| 92 | unknown2, | ||
| 93 | unknown3, | ||
| 94 | unknown4, | ||
| 95 | }; | ||
| 96 | |||
| 97 | // This is nn::irsensor::IrCameraHandle | ||
| 98 | struct IrCameraHandle { | ||
| 99 | u8 npad_id{}; | ||
| 100 | Core::HID::NpadStyleIndex npad_type{Core::HID::NpadStyleIndex::None}; | ||
| 101 | INSERT_PADDING_BYTES(2); | ||
| 102 | }; | ||
| 103 | static_assert(sizeof(IrCameraHandle) == 4, "IrCameraHandle is an invalid size"); | ||
| 104 | |||
| 105 | struct IrsRect { | ||
| 106 | s16 x; | ||
| 107 | s16 y; | ||
| 108 | s16 width; | ||
| 109 | s16 height; | ||
| 110 | }; | ||
| 111 | |||
| 112 | // This is nn::irsensor::PackedMcuVersion | ||
| 113 | struct PackedMcuVersion { | ||
| 114 | u16 major; | ||
| 115 | u16 minor; | ||
| 116 | }; | ||
| 117 | static_assert(sizeof(PackedMcuVersion) == 4, "PackedMcuVersion is an invalid size"); | ||
| 118 | |||
| 119 | // This is nn::irsensor::MomentProcessorConfig | ||
| 120 | struct MomentProcessorConfig { | ||
| 121 | u64 exposire_time; | ||
| 122 | u8 light_target; | ||
| 123 | u8 gain; | ||
| 124 | u8 is_negative_used; | ||
| 125 | INSERT_PADDING_BYTES(7); | ||
| 126 | IrsRect window_of_interest; | ||
| 127 | u8 preprocess; | ||
| 128 | u8 preprocess_intensity_threshold; | ||
| 129 | INSERT_PADDING_BYTES(5); | ||
| 130 | }; | ||
| 131 | static_assert(sizeof(MomentProcessorConfig) == 0x28, | ||
| 132 | "MomentProcessorConfig is an invalid size"); | ||
| 133 | |||
| 134 | // This is nn::irsensor::PackedMomentProcessorConfig | ||
| 135 | struct PackedMomentProcessorConfig { | ||
| 136 | u64 exposire_time; | ||
| 137 | u8 light_target; | ||
| 138 | u8 gain; | ||
| 139 | u8 is_negative_used; | ||
| 140 | INSERT_PADDING_BYTES(5); | ||
| 141 | IrsRect window_of_interest; | ||
| 142 | PackedMcuVersion required_mcu_version; | ||
| 143 | u8 preprocess; | ||
| 144 | u8 preprocess_intensity_threshold; | ||
| 145 | INSERT_PADDING_BYTES(2); | ||
| 146 | }; | ||
| 147 | static_assert(sizeof(PackedMomentProcessorConfig) == 0x20, | ||
| 148 | "PackedMomentProcessorConfig is an invalid size"); | ||
| 149 | |||
| 150 | // This is nn::irsensor::ClusteringProcessorConfig | ||
| 151 | struct ClusteringProcessorConfig { | ||
| 152 | u64 exposire_time; | ||
| 153 | u32 light_target; | ||
| 154 | u32 gain; | ||
| 155 | u8 is_negative_used; | ||
| 156 | INSERT_PADDING_BYTES(7); | ||
| 157 | IrsRect window_of_interest; | ||
| 158 | u32 pixel_count_min; | ||
| 159 | u32 pixel_count_max; | ||
| 160 | u32 object_intensity_min; | ||
| 161 | u8 is_external_light_filter_enabled; | ||
| 162 | INSERT_PADDING_BYTES(3); | ||
| 163 | }; | ||
| 164 | static_assert(sizeof(ClusteringProcessorConfig) == 0x30, | ||
| 165 | "ClusteringProcessorConfig is an invalid size"); | ||
| 166 | |||
| 167 | // This is nn::irsensor::PackedClusteringProcessorConfig | ||
| 168 | struct PackedClusteringProcessorConfig { | ||
| 169 | u64 exposire_time; | ||
| 170 | u8 light_target; | ||
| 171 | u8 gain; | ||
| 172 | u8 is_negative_used; | ||
| 173 | INSERT_PADDING_BYTES(5); | ||
| 174 | IrsRect window_of_interest; | ||
| 175 | PackedMcuVersion required_mcu_version; | ||
| 176 | u32 pixel_count_min; | ||
| 177 | u32 pixel_count_max; | ||
| 178 | u32 object_intensity_min; | ||
| 179 | u8 is_external_light_filter_enabled; | ||
| 180 | INSERT_PADDING_BYTES(2); | ||
| 181 | }; | ||
| 182 | static_assert(sizeof(PackedClusteringProcessorConfig) == 0x30, | ||
| 183 | "PackedClusteringProcessorConfig is an invalid size"); | ||
| 184 | |||
| 185 | // This is nn::irsensor::PackedImageTransferProcessorConfig | ||
| 186 | struct PackedImageTransferProcessorConfig { | ||
| 187 | u64 exposire_time; | ||
| 188 | u8 light_target; | ||
| 189 | u8 gain; | ||
| 190 | u8 is_negative_used; | ||
| 191 | INSERT_PADDING_BYTES(5); | ||
| 192 | PackedMcuVersion required_mcu_version; | ||
| 193 | u8 format; | ||
| 194 | INSERT_PADDING_BYTES(3); | ||
| 195 | }; | ||
| 196 | static_assert(sizeof(PackedImageTransferProcessorConfig) == 0x18, | ||
| 197 | "PackedImageTransferProcessorConfig is an invalid size"); | ||
| 198 | |||
| 199 | // This is nn::irsensor::PackedTeraPluginProcessorConfig | ||
| 200 | struct PackedTeraPluginProcessorConfig { | ||
| 201 | PackedMcuVersion required_mcu_version; | ||
| 202 | u8 mode; | ||
| 203 | INSERT_PADDING_BYTES(3); | ||
| 204 | }; | ||
| 205 | static_assert(sizeof(PackedTeraPluginProcessorConfig) == 0x8, | ||
| 206 | "PackedTeraPluginProcessorConfig is an invalid size"); | ||
| 207 | |||
| 208 | // This is nn::irsensor::PackedPointingProcessorConfig | ||
| 209 | struct PackedPointingProcessorConfig { | ||
| 210 | IrsRect window_of_interest; | ||
| 211 | PackedMcuVersion required_mcu_version; | ||
| 212 | }; | ||
| 213 | static_assert(sizeof(PackedPointingProcessorConfig) == 0xC, | ||
| 214 | "PackedPointingProcessorConfig is an invalid size"); | ||
| 215 | |||
| 216 | // This is nn::irsensor::PackedFunctionLevel | ||
| 217 | struct PackedFunctionLevel { | ||
| 218 | IrSensorFunctionLevel function_level; | ||
| 219 | INSERT_PADDING_BYTES(3); | ||
| 220 | }; | ||
| 221 | static_assert(sizeof(PackedFunctionLevel) == 0x4, "PackedFunctionLevel is an invalid size"); | ||
| 222 | |||
| 223 | // This is nn::irsensor::PackedImageTransferProcessorExConfig | ||
| 224 | struct PackedImageTransferProcessorExConfig { | ||
| 225 | u64 exposire_time; | ||
| 226 | u8 light_target; | ||
| 227 | u8 gain; | ||
| 228 | u8 is_negative_used; | ||
| 229 | INSERT_PADDING_BYTES(5); | ||
| 230 | PackedMcuVersion required_mcu_version; | ||
| 231 | ImageTransferProcessorFormat origin_format; | ||
| 232 | ImageTransferProcessorFormat trimming_format; | ||
| 233 | u16 trimming_start_x; | ||
| 234 | u16 trimming_start_y; | ||
| 235 | u8 is_external_light_filter_enabled; | ||
| 236 | INSERT_PADDING_BYTES(3); | ||
| 237 | }; | ||
| 238 | static_assert(sizeof(PackedImageTransferProcessorExConfig) == 0x20, | ||
| 239 | "PackedImageTransferProcessorExConfig is an invalid size"); | ||
| 240 | |||
| 241 | // This is nn::irsensor::PackedIrLedProcessorConfig | ||
| 242 | struct PackedIrLedProcessorConfig { | ||
| 243 | PackedMcuVersion required_mcu_version; | ||
| 244 | u8 light_target; | ||
| 245 | INSERT_PADDING_BYTES(3); | ||
| 246 | }; | ||
| 247 | static_assert(sizeof(PackedIrLedProcessorConfig) == 0x8, | ||
| 248 | "PackedIrLedProcessorConfig is an invalid size"); | ||
| 249 | |||
| 20 | void ActivateIrsensor(Kernel::HLERequestContext& ctx); | 250 | void ActivateIrsensor(Kernel::HLERequestContext& ctx); |
| 21 | void DeactivateIrsensor(Kernel::HLERequestContext& ctx); | 251 | void DeactivateIrsensor(Kernel::HLERequestContext& ctx); |
| 22 | void GetIrsensorSharedMemoryHandle(Kernel::HLERequestContext& ctx); | 252 | void GetIrsensorSharedMemoryHandle(Kernel::HLERequestContext& ctx); |
| @@ -35,8 +265,6 @@ private: | |||
| 35 | void RunIrLedProcessor(Kernel::HLERequestContext& ctx); | 265 | void RunIrLedProcessor(Kernel::HLERequestContext& ctx); |
| 36 | void StopImageProcessorAsync(Kernel::HLERequestContext& ctx); | 266 | void StopImageProcessorAsync(Kernel::HLERequestContext& ctx); |
| 37 | void ActivateIrsensorWithFunctionLevel(Kernel::HLERequestContext& ctx); | 267 | void ActivateIrsensorWithFunctionLevel(Kernel::HLERequestContext& ctx); |
| 38 | |||
| 39 | const u32 device_handle{0xABCD}; | ||
| 40 | }; | 268 | }; |
| 41 | 269 | ||
| 42 | class IRS_SYS final : public ServiceFramework<IRS_SYS> { | 270 | class IRS_SYS final : public ServiceFramework<IRS_SYS> { |
diff --git a/src/video_core/engines/maxwell_3d.cpp b/src/video_core/engines/maxwell_3d.cpp index 7d0cb8fce..3a4646289 100644 --- a/src/video_core/engines/maxwell_3d.cpp +++ b/src/video_core/engines/maxwell_3d.cpp | |||
| @@ -595,8 +595,8 @@ void Maxwell3D::DrawArrays() { | |||
| 595 | 595 | ||
| 596 | std::optional<u64> Maxwell3D::GetQueryResult() { | 596 | std::optional<u64> Maxwell3D::GetQueryResult() { |
| 597 | switch (regs.query.query_get.select) { | 597 | switch (regs.query.query_get.select) { |
| 598 | case Regs::QuerySelect::Zero: | 598 | case Regs::QuerySelect::Payload: |
| 599 | return 0; | 599 | return regs.query.query_sequence; |
| 600 | case Regs::QuerySelect::SamplesPassed: | 600 | case Regs::QuerySelect::SamplesPassed: |
| 601 | // Deferred. | 601 | // Deferred. |
| 602 | rasterizer->Query(regs.query.QueryAddress(), QueryType::SamplesPassed, | 602 | rasterizer->Query(regs.query.QueryAddress(), QueryType::SamplesPassed, |
diff --git a/src/video_core/engines/maxwell_3d.h b/src/video_core/engines/maxwell_3d.h index c0c2c7d96..434ba0877 100644 --- a/src/video_core/engines/maxwell_3d.h +++ b/src/video_core/engines/maxwell_3d.h | |||
| @@ -93,7 +93,7 @@ public: | |||
| 93 | }; | 93 | }; |
| 94 | 94 | ||
| 95 | enum class QuerySelect : u32 { | 95 | enum class QuerySelect : u32 { |
| 96 | Zero = 0, | 96 | Payload = 0, |
| 97 | TimeElapsed = 2, | 97 | TimeElapsed = 2, |
| 98 | TransformFeedbackPrimitivesGenerated = 11, | 98 | TransformFeedbackPrimitivesGenerated = 11, |
| 99 | PrimitivesGenerated = 18, | 99 | PrimitivesGenerated = 18, |