Switched some error messages to use sdl's logging system
This commit is contained in:
parent
4f9e31a69d
commit
c13cb11313
1 changed files with 4 additions and 1 deletions
|
|
@ -73,7 +73,8 @@ Window::Window() {
|
|||
[this](wgpu::RequestAdapterStatus status, wgpu::Adapter a,
|
||||
wgpu::StringView message) {
|
||||
if (status != wgpu::RequestAdapterStatus::Success) {
|
||||
std::cout << "RequestAdapter: " << message << "\n";
|
||||
SDL_LogError(SDL_LOG_CATEGORY_ERROR, "Could not get WGPU adapter: %s",
|
||||
message.data);
|
||||
exit(0);
|
||||
}
|
||||
adapter = std::move(a);
|
||||
|
|
@ -93,6 +94,8 @@ Window::Window() {
|
|||
wgpu::StringView message) {
|
||||
if (status != wgpu::RequestDeviceStatus::Success) {
|
||||
std::cout << "RequestDevice: " << message << "\n";
|
||||
SDL_LogError(SDL_LOG_CATEGORY_ERROR, "Could not get WGPU device: %s",
|
||||
message.data);
|
||||
exit(0);
|
||||
}
|
||||
device = std::move(d);
|
||||
|
|
|
|||
Loading…
Reference in a new issue