Class RawSink
java.lang.Object
org.wpilib.vision.camera.VideoSink
org.wpilib.vision.camera.ImageSink
org.wpilib.vision.camera.raw.RawSink
- All Implemented Interfaces:
AutoCloseable
-
Nested Class Summary
Nested classes/interfaces inherited from class VideoSink
VideoSink.Kind -
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class ImageSink
getError, setDescription, setEnabledMethods inherited from class VideoSink
close, enumerateProperties, enumerateSinks, equals, getConfigJson, getDescription, getHandle, getKind, getKindFromInt, getName, getProperty, getSource, getSourceProperty, hashCode, isValid, setConfigJson, setSource
-
Constructor Details
-
RawSink
-
-
Method Details
-
grabFrame
Wait for the next frame and get the image. Times out (returning 0) after 0.225 seconds. The provided image will have three 8-bit channels stored in BGR order.- Parameters:
frame- The frame object in which to store the image.- Returns:
- Frame time, or 0 on error (call getError() to obtain the error message); the frame time is in the same time base as wpi::Now(), and is in 1 us increments.
-
grabFrame
Wait for the next frame and get the image. Times out (returning 0) after timeout seconds. The provided image will have three 8-bit channels stored in BGR order.- Parameters:
frame- The frame object in which to store the image.timeout- The frame timeout in seconds.- Returns:
- Frame time, or 0 on error (call getError() to obtain the error message); the frame time is in the same time base as wpi::Now(), and is in 1 us increments.
-
grabFrameNoTimeout
Wait for the next frame and get the image. May block forever. The provided image will have three 8-bit channels stored in BGR order.- Parameters:
frame- The frame object in which to store the image.- Returns:
- Frame time, or 0 on error (call getError() to obtain the error message); the frame time is in the same time base as wpi::Now(), and is in 1 us increments.
-