Documentation ¶
Overview ¶
Package videosource implements various camera models including webcam
Index ¶
- Variables
- func Discover(ctx context.Context, getDrivers func() []driver.Driver, logger logging.Logger) (*pb.Webcams, error)
- func NewWebcam(ctx context.Context, deps resource.Dependencies, conf resource.Config, ...) (camera.Camera, error)
- type CameraConfig
- type StaticSource
- func (ss *StaticSource) Close(ctx context.Context) error
- func (ss *StaticSource) Images(ctx context.Context) ([]camera.NamedImage, resource.ResponseMetadata, error)
- func (ss *StaticSource) NextPointCloud(ctx context.Context) (pointcloud.PointCloud, error)
- func (ss *StaticSource) Read(ctx context.Context) (image.Image, func(), error)
- type WebcamConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var ModelWebcam = resource.DefaultModelFamily.WithModel("webcam")
ModelWebcam is the name of the webcam component.
Functions ¶
Types ¶
type CameraConfig ¶
CameraConfig is collection of configuration options for a camera.
type StaticSource ¶
StaticSource is a fixed, stored image. Used primarily for testing.
func (*StaticSource) Close ¶
func (ss *StaticSource) Close(ctx context.Context) error
Close does nothing.
func (*StaticSource) Images ¶ added in v0.16.0
func (ss *StaticSource) Images(ctx context.Context) ([]camera.NamedImage, resource.ResponseMetadata, error)
Images returns the saved color and depth image if they are present.
func (*StaticSource) NextPointCloud ¶
func (ss *StaticSource) NextPointCloud(ctx context.Context) (pointcloud.PointCloud, error)
NextPointCloud returns the point cloud from projecting the rgb and depth image using the intrinsic parameters.
type WebcamConfig ¶ added in v0.2.36
type WebcamConfig struct { CameraParameters *transform.PinholeCameraIntrinsics `json:"intrinsic_parameters,omitempty"` DistortionParameters *transform.BrownConrady `json:"distortion_parameters,omitempty"` Debug bool `json:"debug,omitempty"` Format string `json:"format,omitempty"` Path string `json:"video_path"` Width int `json:"width_px,omitempty"` Height int `json:"height_px,omitempty"` FrameRate float32 `json:"frame_rate,omitempty"` }
WebcamConfig is the attribute struct for webcams.
Click to show internal directories.
Click to hide internal directories.