Skip to content

Commit bbfc9e0

Browse files
committed
🔧
1 parent f605ca4 commit bbfc9e0

2 files changed

Lines changed: 12 additions & 11 deletions

File tree

packages/webgpu/cpp/rnwgpu/api/GPUAdapter.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -82,16 +82,16 @@ async::AsyncTaskHandle GPUAdapter::requestDevice(
8282
auto creationRuntime = getCreationRuntime();
8383
return _async->postTask(
8484
[this, aDescriptor, descriptor, label = std::move(label),
85-
deviceLostBinding, creationRuntime](
86-
const async::AsyncTaskHandle::ResolveFunction &resolve,
87-
const async::AsyncTaskHandle::RejectFunction &reject) {
85+
deviceLostBinding,
86+
creationRuntime](const async::AsyncTaskHandle::ResolveFunction &resolve,
87+
const async::AsyncTaskHandle::RejectFunction &reject) {
8888
(void)descriptor;
8989
_instance.RequestDevice(
9090
&aDescriptor, wgpu::CallbackMode::AllowProcessEvents,
91-
[asyncRunner = _async, resolve, reject, label,
92-
creationRuntime, deviceLostBinding](
93-
wgpu::RequestDeviceStatus status, wgpu::Device device,
94-
wgpu::StringView message) mutable {
91+
[asyncRunner = _async, resolve, reject, label, creationRuntime,
92+
deviceLostBinding](wgpu::RequestDeviceStatus status,
93+
wgpu::Device device,
94+
wgpu::StringView message) mutable {
9595
if (message.length) {
9696
fprintf(stderr, "%s", message.data);
9797
}

packages/webgpu/cpp/rnwgpu/api/GPUTexture.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,10 +201,12 @@ class GPUTexture : public m::HybridObject {
201201
case wgpu::TextureFormat::R10X6BG10X6Biplanar420Unorm:
202202
case wgpu::TextureFormat::R8BG8A8Triplanar420Unorm:
203203
case wgpu::TextureFormat::R8BG8Biplanar422Unorm:
204-
case wgpu::TextureFormat::R8BG8Biplanar444Unorm:
205204
case wgpu::TextureFormat::R10X6BG10X6Biplanar422Unorm:
206-
case wgpu::TextureFormat::R10X6BG10X6Biplanar444Unorm:
207205
return {1, 1, 2, false};
206+
case wgpu::TextureFormat::R8BG8Biplanar444Unorm:
207+
return {1, 1, 3, false};
208+
case wgpu::TextureFormat::R10X6BG10X6Biplanar444Unorm:
209+
return {1, 1, 6, false};
208210
case wgpu::TextureFormat::Undefined:
209211
default:
210212
return {1, 1, 4, false};
@@ -246,8 +248,7 @@ class GPUTexture : public m::HybridObject {
246248
if (totalMemory == 0) {
247249
totalMemory = kAlignment;
248250
} else {
249-
totalMemory =
250-
((totalMemory + kAlignment - 1) / kAlignment) * kAlignment;
251+
totalMemory = ((totalMemory + kAlignment - 1) / kAlignment) * kAlignment;
251252
}
252253
return totalMemory;
253254
}

0 commit comments

Comments
 (0)