|
| 1 | +2020-10-22 Don Olmstead < [email protected]> |
| 2 | + |
| 3 | + [WebGPU] Add Dawn implementation skeleton |
| 4 | + https://bugs.webkit.org/show_bug.cgi?id=217982 |
| 5 | + |
| 6 | + Reviewed by Myles C. Maxfield. |
| 7 | + |
| 8 | + Add an empty implementation of the WebGPU types. This gets WebGPU built and linking |
| 9 | + using Dawn. |
| 10 | + |
| 11 | + * PlatformWinCairo.cmake: |
| 12 | + * platform/Dawn.cmake: Added. |
| 13 | + * platform/graphics/gpu/GPUPlatformTypes.h: |
| 14 | + * platform/graphics/gpu/dawn/GPUBindGroupAllocatorDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 15 | + (WebCore::GPUBindGroupAllocator::create): |
| 16 | + (WebCore::GPUBindGroupAllocator::GPUBindGroupAllocator): |
| 17 | + (WebCore::GPUBindGroupAllocator::reallocate): |
| 18 | + (WebCore::GPUBindGroupAllocator::tryReset): |
| 19 | + * platform/graphics/gpu/dawn/GPUBindGroupDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 20 | + (WebCore::GPUBindGroup::tryCreate): |
| 21 | + (WebCore::GPUBindGroup::GPUBindGroup): |
| 22 | + (WebCore::GPUBindGroup::~GPUBindGroup): |
| 23 | + * platform/graphics/gpu/dawn/GPUBindGroupLayoutDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 24 | + (WebCore::GPUBindGroupLayout::tryCreate): |
| 25 | + * platform/graphics/gpu/dawn/GPUBufferDawn.cpp: Added. |
| 26 | + (WebCore::GPUBuffer::tryCreate): |
| 27 | + (WebCore::GPUBuffer::GPUBuffer): |
| 28 | + (WebCore::GPUBuffer::~GPUBuffer): |
| 29 | + (WebCore::GPUBuffer::isReadOnly const): |
| 30 | + (WebCore::GPUBuffer::state const): |
| 31 | + (WebCore::GPUBuffer::mapOnCreation): |
| 32 | + (WebCore::GPUBuffer::registerMappingCallback): |
| 33 | + (WebCore::GPUBuffer::runMappingCallback): |
| 34 | + (WebCore::GPUBuffer::stagingBufferForRead): |
| 35 | + (WebCore::GPUBuffer::stagingBufferForWrite): |
| 36 | + (WebCore::GPUBuffer::copyStagingBufferToGPU): |
| 37 | + (WebCore::GPUBuffer::unmap): |
| 38 | + (WebCore::GPUBuffer::destroy): |
| 39 | + * platform/graphics/gpu/dawn/GPUCommandBufferDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 40 | + (WebCore::GPUCommandBuffer::tryCreate): |
| 41 | + (WebCore::GPUCommandBuffer::GPUCommandBuffer): |
| 42 | + (WebCore::GPUCommandBuffer::copyBufferToBuffer): |
| 43 | + (WebCore::GPUCommandBuffer::copyBufferToTexture): |
| 44 | + (WebCore::GPUCommandBuffer::copyTextureToBuffer): |
| 45 | + (WebCore::GPUCommandBuffer::copyTextureToTexture): |
| 46 | + * platform/graphics/gpu/dawn/GPUComputePassEncoderDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 47 | + (WebCore::GPUComputePassEncoder::tryCreate): |
| 48 | + (WebCore::GPUComputePassEncoder::GPUComputePassEncoder): |
| 49 | + (WebCore::GPUComputePassEncoder::setPipeline): |
| 50 | + (WebCore::GPUComputePassEncoder::dispatch): |
| 51 | + (WebCore::GPUComputePassEncoder::platformPassEncoder const): |
| 52 | + * platform/graphics/gpu/dawn/GPUComputePipelineDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 53 | + (WebCore::GPUComputePipeline::tryCreate): |
| 54 | + (WebCore::GPUComputePipeline::recompile): |
| 55 | + * platform/graphics/gpu/dawn/GPUDeviceDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 56 | + (WebCore::GPUDevice::tryCreate): |
| 57 | + (WebCore::GPUDevice::GPUDevice): |
| 58 | + * platform/graphics/gpu/dawn/GPUPlatformTypesDawn.h: Added. |
| 59 | + (WebCore::HandleDeleter<PlatformBuffer>::operator()): |
| 60 | + (WebCore::HandleDeleter<PlatformCommandBuffer>::operator()): |
| 61 | + (WebCore::HandleDeleter<PlatformComputePassEncoder>::operator()): |
| 62 | + (WebCore::HandleDeleter<PlatformComputePipeline>::operator()): |
| 63 | + (WebCore::HandleDeleter<PlatformDevice>::operator()): |
| 64 | + (WebCore::HandleDeleter<PlatformDrawable>::operator()): |
| 65 | + (WebCore::HandleDeleter<PlatformProgrammablePassEncoder>::operator()): |
| 66 | + (WebCore::HandleDeleter<PlatformQueue>::operator()): |
| 67 | + (WebCore::HandleDeleter<PlatformRenderPassEncoder>::operator()): |
| 68 | + (WebCore::HandleDeleter<PlatformRenderPipeline>::operator()): |
| 69 | + (WebCore::HandleDeleter<PlatformSampler>::operator()): |
| 70 | + (WebCore::HandleDeleter<PlatformShaderModule>::operator()): |
| 71 | + (WebCore::HandleDeleter<PlatformSwapLayer>::operator()): |
| 72 | + (WebCore::HandleDeleter<PlatformTexture>::operator()): |
| 73 | + * platform/graphics/gpu/dawn/GPUProgrammablePassEncoderDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 74 | + (WebCore::GPUProgrammablePassEncoder::endPass): |
| 75 | + (WebCore::GPUProgrammablePassEncoder::setBindGroup): |
| 76 | + * platform/graphics/gpu/dawn/GPUQueueDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 77 | + (WebCore::GPUQueue::tryCreate): |
| 78 | + (WebCore::GPUQueue::GPUQueue): |
| 79 | + (WebCore::GPUQueue::submit): |
| 80 | + (WebCore::GPUQueue::label const): |
| 81 | + (WebCore::GPUQueue::setLabel const): |
| 82 | + * platform/graphics/gpu/dawn/GPURenderPassEncoderDawn.cpp: Added. |
| 83 | + (WebCore::GPURenderPassEncoder::tryCreate): |
| 84 | + (WebCore::GPURenderPassEncoder::GPURenderPassEncoder): |
| 85 | + (WebCore::GPURenderPassEncoder::platformPassEncoder const): |
| 86 | + (WebCore::GPURenderPassEncoder::setPipeline): |
| 87 | + (WebCore::GPURenderPassEncoder::setBlendColor): |
| 88 | + (WebCore::GPURenderPassEncoder::setViewport): |
| 89 | + (WebCore::GPURenderPassEncoder::setScissorRect): |
| 90 | + (WebCore::GPURenderPassEncoder::setIndexBuffer): |
| 91 | + (WebCore::GPURenderPassEncoder::setVertexBuffers): |
| 92 | + (WebCore::GPURenderPassEncoder::draw): |
| 93 | + (WebCore::GPURenderPassEncoder::drawIndexed): |
| 94 | + * platform/graphics/gpu/dawn/GPURenderPipelineDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 95 | + (WebCore::GPURenderPipeline::tryCreate): |
| 96 | + (WebCore::GPURenderPipeline::recompile): |
| 97 | + * platform/graphics/gpu/dawn/GPUSamplerDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 98 | + (WebCore::GPUSampler::tryCreate): |
| 99 | + (WebCore::GPUSampler::GPUSampler): |
| 100 | + * platform/graphics/gpu/dawn/GPUShaderModuleDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 101 | + (WebCore::GPUShaderModule::tryCreate): |
| 102 | + (WebCore::GPUShaderModule::GPUShaderModule): |
| 103 | + * platform/graphics/gpu/dawn/GPUSwapChainDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 104 | + (WebCore::GPUSwapChain::tryCreate): |
| 105 | + (WebCore::GPUSwapChain::GPUSwapChain): |
| 106 | + (WebCore::GPUSwapChain::tryGetCurrentTexture): |
| 107 | + (WebCore::GPUSwapChain::present): |
| 108 | + (WebCore::GPUSwapChain::reshape): |
| 109 | + (WebCore::GPUSwapChain::platformLayer const): |
| 110 | + * platform/graphics/gpu/dawn/GPUTextureDawn.cpp: Copied from Source/WebCore/platform/graphics/gpu/GPUPlatformTypes.h. |
| 111 | + (WebCore::GPUTexture::tryCreate): |
| 112 | + (WebCore::GPUTexture::create): |
| 113 | + (WebCore::GPUTexture::GPUTexture): |
| 114 | + (WebCore::GPUTexture::tryCreateDefaultTextureView): |
| 115 | + |
1 | 116 | 2020-10-22 Chris Dumez < [email protected]>
|
2 | 117 |
|
3 | 118 | Turn ScriptExecutionContext::vm() into a pure virtual function
|
|
0 commit comments