mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-21 10:49:14 +00:00
dawn_wire: Support deserializing s->c chained structs
Chained structs *may* contain objects which means deserialization may need an ObjectIdResolver. However, in practice, we never need to send chained structs from the server to the client that contain objects for a valid command. The one upcoming need for chained server->client structs is to serialize limit structs. Because limit structs never need objects, we provide a dummy implementation of the ObjectIdResolver which always yields an error. An analogous change is done for ObjectIdProvider. These classes will be used in a follow-up CL. Bug: dawn:685 Change-Id: I1c0f3f2d080377f2e1a77bc6e896f24d3d9ab931 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/63981 Commit-Queue: Austin Eng <enga@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
@@ -21,7 +21,7 @@ class WireWGPUDevicePropertiesTests : public testing::Test {};
|
||||
|
||||
// Test that the serialization and deserialization of WGPUDeviceProperties can work correctly.
|
||||
TEST_F(WireWGPUDevicePropertiesTests, SerializeWGPUDeviceProperties) {
|
||||
WGPUDeviceProperties sentWGPUDeviceProperties;
|
||||
WGPUDeviceProperties sentWGPUDeviceProperties = {};
|
||||
sentWGPUDeviceProperties.textureCompressionBC = true;
|
||||
// Set false to test that the serialization can handle both true and false correctly.
|
||||
sentWGPUDeviceProperties.pipelineStatisticsQuery = false;
|
||||
|
||||
Reference in New Issue
Block a user