Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
// Generated by jextract
package com.littlekt.wgpu;
import java.lang.invoke.*;
import java.lang.foreign.*;
import java.nio.ByteOrder;
import java.util.*;
import java.util.function.*;
import java.util.stream.*;
import static java.lang.foreign.ValueLayout.*;
import static java.lang.foreign.MemoryLayout.PathElement.*;
/**
* {@snippet lang=c :
* typedef void (*WGPUProcCommandEncoderResolveQuerySet)(WGPUCommandEncoder, WGPUQuerySet, uint32_t, uint32_t, WGPUBuffer, uint64_t)
* }
*/
public class WGPUProcCommandEncoderResolveQuerySet {
WGPUProcCommandEncoderResolveQuerySet() {
// Should not be called directly
}
/**
* The function pointer signature, expressed as a functional interface
*/
public interface Function {
void apply(MemorySegment commandEncoder, MemorySegment querySet, int firstQuery, int queryCount, MemorySegment destination, long destinationOffset);
}
private static final FunctionDescriptor $DESC = FunctionDescriptor.ofVoid(
WGPU.C_POINTER,
WGPU.C_POINTER,
WGPU.C_INT,
WGPU.C_INT,
WGPU.C_POINTER,
WGPU.C_LONG_LONG
);
/**
* The descriptor of this function pointer
*/
public static FunctionDescriptor descriptor() {
return $DESC;
}
private static final MethodHandle UP$MH = WGPU.upcallHandle(WGPUProcCommandEncoderResolveQuerySet.Function.class, "apply", $DESC);
/**
* Allocates a new upcall stub, whose implementation is defined by {@code fi}.
* The lifetime of the returned segment is managed by {@code arena}
*/
public static MemorySegment allocate(WGPUProcCommandEncoderResolveQuerySet.Function fi, Arena arena) {
return Linker.nativeLinker().upcallStub(UP$MH.bindTo(fi), $DESC, arena);
}
private static final MethodHandle DOWN$MH = Linker.nativeLinker().downcallHandle($DESC);
/**
* Invoke the upcall stub {@code funcPtr}, with given parameters
*/
public static void invoke(MemorySegment funcPtr,MemorySegment commandEncoder, MemorySegment querySet, int firstQuery, int queryCount, MemorySegment destination, long destinationOffset) {
try {
DOWN$MH.invokeExact(funcPtr, commandEncoder, querySet, firstQuery, queryCount, destination, destinationOffset);
} catch (Throwable ex$) {
throw new AssertionError("should not reach here", ex$);
}
}
}