summaryrefslogtreecommitdiff
path: root/src/gpu/gpu.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gpu/gpu.h')
-rw-r--r--src/gpu/gpu.h17
1 files changed, 4 insertions, 13 deletions
diff --git a/src/gpu/gpu.h b/src/gpu/gpu.h
index c2c0670..eb3dd8a 100644
--- a/src/gpu/gpu.h
+++ b/src/gpu/gpu.h
@@ -16,13 +16,9 @@
#include <webgpu/wgpu.h>
-static inline const char *str_view(const char *str) {
- return str;
-}
+static inline const char *str_view(const char *str) { return str; }
-static inline const char *label_view(const char *str) {
- return str;
-}
+static inline const char *label_view(const char *str) { return str; }
#define WGPUSType_ShaderSourceWGSL WGPUSType_ShaderModuleWGSLDescriptor
@@ -40,8 +36,6 @@ using WGPUShaderSourceWGSL = WGPUShaderModuleWGSLDescriptor;
#else
-
-
// Native (macOS/Linux) using newer wgpu-native
#include <webgpu.h>
@@ -49,9 +43,7 @@ using WGPUShaderSourceWGSL = WGPUShaderModuleWGSLDescriptor;
#include <wgpu.h>
static inline WGPUStringView str_view(const char *str) {
-
- if (!str)
- return {nullptr, 0};
+ if (!str) return {nullptr, 0};
return {str, strlen(str)};
}
@@ -60,8 +52,7 @@ static inline WGPUStringView label_view(const char *str) {
#ifndef STRIP_ALL
- if (!str)
- return {nullptr, 0};
+ if (!str) return {nullptr, 0};
return {str, strlen(str)};