webgpu-native / webgpu-headers

https://webgpu-native.github.io/webgpu-headers/
BSD 3-Clause "New" or "Revised" License
370 stars 43 forks source link

timestampWrites is an array in JS. It needs a count #313

Closed Andersbakken closed 2 months ago

Kangz commented 2 months ago

It seems like it isn't? See the idl below.

dictionary GPUComputePassDescriptor
         : GPUObjectDescriptorBase {
    GPUComputePassTimestampWrites timestampWrites;
};

dictionary GPUComputePassTimestampWrites {
    required GPUQuerySet querySet;
    GPUSize32 beginningOfPassWriteIndex;
    GPUSize32 endOfPassWriteIndex;
};
beaufortfrancois commented 2 months ago

@Kangz is right. See a JS example at https://developer.chrome.com/blog/new-in-webgpu-121#timestamp_queries_in_compute_and_render_passes

Kangz commented 2 months ago

Tentatively closing.

kainino0x commented 2 months ago

I think it used to be an array, but indeed now it is just a nullable sub-structure.

Andersbakken commented 2 months ago

Ah. My bad.

Sorry about that.

regards

Anders

On Mon, Jul 22, 2024 at 10:31 PM Kai Ninomiya @.***> wrote:

I think it used to be an array, but indeed now it is just a nullable sub-structure.

— Reply to this email directly, view it on GitHub https://github.com/webgpu-native/webgpu-headers/pull/313#issuecomment-2243761878, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAR2SU52K6VGYSIIPVQODDZNVTYJAVCNFSM6AAAAABLGLDNHCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENBTG43DCOBXHA . You are receiving this because you authored the thread.Message ID: @.***>