MCPcopy Create free account
hub / github.com/Kitware/VTK / CreateBuffer

Method CreateBuffer

Rendering/WebGPU/vtkWebGPUConfiguration.cxx:816–832  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

814
815//------------------------------------------------------------------------------
816wgpu::Buffer vtkWebGPUConfiguration::CreateBuffer(unsigned long sizeBytes, wgpu::BufferUsage usage,
817 bool mappedAtCreation /*=false*/, const char* label /*=nullptr*/)
818{
819 auto& internals = (*this->Internals);
820 if (!internals.DeviceReady)
821 {
822 vtkWarningMacro(<< "Cannot create buffer because device is not ready.");
823 return nullptr;
824 }
825 wgpu::BufferDescriptor bufferDescriptor;
826 bufferDescriptor.label = label == nullptr ? "(nolabel)" : label;
827 bufferDescriptor.size = sizeBytes;
828 bufferDescriptor.usage = usage;
829 bufferDescriptor.mappedAtCreation = mappedAtCreation;
830
831 return this->CreateBuffer(bufferDescriptor);
832}
833
834//------------------------------------------------------------------------------
835wgpu::Buffer vtkWebGPUConfiguration::CreateBuffer(const wgpu::BufferDescriptor& bufferDescriptor)

Callers 15

CreateBuffersMethod · 0.45
ReadTextureFromGPUMethod · 0.45
SetPixelDataMethod · 0.45
SetRGBAPixelDataMethod · 0.45
SetRGBACharPixelDataMethod · 0.45
CreateBindGroupsMethod · 0.45
RenderPieceFunction · 0.45

Calls 1