14#if defined(__EMSCRIPTEN__)
15#include <emscripten.h>
23 case wgpu::TextureFormat::RGBA8Unorm:
return 4;
24 case wgpu::TextureFormat::BGRA8Unorm:
return 4;
25 case wgpu::TextureFormat::R8Unorm:
return 1;
26 case wgpu::TextureFormat::RGBA16Float:
return 8;
27 case wgpu::TextureFormat::R16Float:
return 2;
28 case wgpu::TextureFormat::RG8Unorm:
return 2;
29 case wgpu::TextureFormat::RGB10A2Unorm:
return 4;
30 case wgpu::TextureFormat::RG16Float:
return 4;
35 case wgpu::TextureFormat::Stencil8:
return 4;
36 case wgpu::TextureFormat::Depth16Unorm:
return 2;
37 case wgpu::TextureFormat::Depth32Float:
return 4;
38 case wgpu::TextureFormat::Depth32FloatStencil8:
return 5;
39 case wgpu::TextureFormat::Depth24PlusStencil8:
return 5;
41#if !defined(__EMSCRIPTEN__)
42 case wgpu::TextureFormat::R16Unorm:
return 2;
43 case wgpu::TextureFormat::RG16Unorm:
return 4;
47 case wgpu::TextureFormat::External:
74#if !defined(__EMSCRIPTEN__)
@ kRGBA_SkColorChannelFlags
@ kRed_SkColorChannelFlag
@ kRG_SkColorChannelFlags
uint32_t uint32_t * format
SkTextureCompressionType DawnFormatToCompressionType(wgpu::TextureFormat format)
uint32_t DawnFormatChannels(wgpu::TextureFormat format)
size_t DawnFormatBytesPerBlock(wgpu::TextureFormat format)