Interface CollectPadsCompareFunction
- All Superinterfaces:
FunctionPointer
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
@Generated("org.javagi.JavaGI")
public interface CollectPadsCompareFunction
extends FunctionPointer
Functional interface declaration of the CollectPadsCompareFunction callback.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionintrun(CollectPads pads, CollectData data1, ClockTime timestamp1, CollectData data2, ClockTime timestamp2) A function for comparing two timestamps of buffers or newsegments collected on one pad.default MemorySegmenttoCallback(Arena arena) Creates a native function pointer to theupcall(MemorySegment, MemorySegment, long, MemorySegment, long, MemorySegment)method.default intupcall(MemorySegment pads, MemorySegment data1, long timestamp1, MemorySegment data2, long timestamp2, MemorySegment userData) Theupcallmethod is called from native code.
-
Method Details
-
run
int run(CollectPads pads, CollectData data1, ClockTime timestamp1, CollectData data2, ClockTime timestamp2) A function for comparing two timestamps of buffers or newsegments collected on one pad.- Parameters:
pads- theGstCollectPadsthat is comparing the timestampsdata1- the firstGstCollectDatatimestamp1- the first timestampdata2- the secondGstCollectDatatimestamp2- the second timestamp- Returns:
- Integer less than zero when first timestamp is deemed older than the second one. Zero if the timestamps are deemed equally old. Integer greater than zero when second timestamp is deemed older than the first one.
-
upcall
default int upcall(MemorySegment pads, MemorySegment data1, long timestamp1, MemorySegment data2, long timestamp2, MemorySegment userData) Theupcallmethod is called from native code. The parameters are marshaled andrun(CollectPads, CollectData, ClockTime, CollectData, ClockTime)is executed. -
toCallback
Creates a native function pointer to theupcall(MemorySegment, MemorySegment, long, MemorySegment, long, MemorySegment)method.- Specified by:
toCallbackin interfaceFunctionPointer- Parameters:
arena- the arena in which the function pointer is allocated- Returns:
- the native function pointer
-