public final class CameraServerData extends edu.wpi.first.shuffleboard.api.data.ComplexData<CameraServerData> implements java.io.Serializable
Constructor and Description |
---|
CameraServerData(java.lang.String name,
org.opencv.core.Mat image,
double fps,
double bandwidth)
Creates a new data object.
|
Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.String,java.lang.Object> |
asMap() |
double |
getBandwidth()
Gets the current bandwidth use of the stream in bytes per second.
|
double |
getFps()
Gets the current framerate of the stream in frames per second.
|
org.opencv.core.Mat |
getImage() |
java.lang.String |
getName() |
CameraServerData |
withImage(org.opencv.core.Mat image)
Creates a new data object identical to this one, but with a different image.
|
public CameraServerData(java.lang.String name, org.opencv.core.Mat image, double fps, double bandwidth)
name
- the name of the cameraimage
- the images being supplied by the stream, or null if the stream is not providing an imagefps
- the current FPS of the stream. If the FPS is unknown, set to -1bandwidth
- the current bandwidth of the stream, in bytes per second. If the bandwidth is unknown, set to -1public java.lang.String getName()
public org.opencv.core.Mat getImage()
public double getFps()
public double getBandwidth()
public java.util.Map<java.lang.String,java.lang.Object> asMap()
asMap
in class edu.wpi.first.shuffleboard.api.data.ComplexData<CameraServerData>
public CameraServerData withImage(org.opencv.core.Mat image)
image
- the image for the new data object