Skip to content

Commit

Permalink
wgpu samples: Dawn native fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
floooh committed Sep 29, 2024
1 parent ab2ff2b commit 1149271
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion wgpu/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ fips_begin_lib(wgpu_entry)
fips_files(wgpu_entry_emsc.c)
else()
fips_files(wgpu_entry_dawn.cc)
fips_libs(webgpu_dawn webgpu_glfw webgpu_cpp)
fips_libs(webgpu_dawn webgpu_glfw)
endif()
fips_end_lib()

Expand Down
4 changes: 2 additions & 2 deletions wgpu/wgpu_entry_dawn.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include "stdio.h"

static WGPUSurface glfw_create_surface_for_window(WGPUInstance instance, void* glfw_window) {
wgpuInstanceReference(instance);
wgpuInstanceAddRef(instance);
const auto cppInstance = wgpu::Instance::Acquire(instance);
WGPUSurface surface = wgpu::glfw::CreateSurfaceForWindow(instance, (GLFWwindow*)glfw_window).MoveToCHandle();
return surface;
Expand Down Expand Up @@ -90,7 +90,7 @@ static void request_adapter_cb(WGPURequestAdapterStatus status, WGPUAdapter adap
WGPUFeatureName_Depth32FloatStencil8
};
WGPUDeviceDescriptor dev_desc = {
.requiredFeaturesCount = 1,
.requiredFeatureCount = 1,
.requiredFeatures = requiredFeatures,
};
wgpuAdapterRequestDevice(adapter, &dev_desc, request_device_cb, userdata);
Expand Down

0 comments on commit 1149271

Please sign in to comment.