client

package
v1.7.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 2, 2023 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bot

type Bot struct {
	// contains filtered or unexported fields
}

type Circle

type Circle struct {
	Center Point   `json:"center"`
	Radius float32 `json:"radius"`
	Style
	Metadata
}

type Line

type Line struct {
	P1 Point `json:"p1"`
	P2 Point `json:"p2"`
	Style
	Metadata
}

type Metadata

type Metadata struct {
	SourceId         string   `json:"sourceId,omitempty"`
	Layer            []string `json:"layer,omitempty"`
	VisibleByDefault bool     `json:"visibleByDefault,omitempty"`
}

type Package

type Package struct {
	FieldWidth     float32           `json:"fieldWidth"`
	FieldLength    float32           `json:"fieldLength"`
	BoundaryWidth  float32           `json:"boundaryWidth"`
	GoalWidth      float32           `json:"goalWidth"`
	GoalDepth      float32           `json:"goalDepth"`
	Shapes         []Shape           `json:"shapes"`
	ActiveSourceId string            `json:"activeSourceId"`
	Sources        map[string]string `json:"sources"`
}

func (*Package) AddCircle

func (p *Package) AddCircle(sourceId string, circle *visualization.Circle)

func (*Package) AddDetectionFrame

func (p *Package) AddDetectionFrame(frame *vision.SSL_DetectionFrame)

func (*Package) AddGeometryShapes

func (p *Package) AddGeometryShapes(geometry *vision.SSL_GeometryData)

func (*Package) AddLineSegment

func (p *Package) AddLineSegment(sourceId string, lineSegment *visualization.LineSegment)

func (*Package) AddTrackedFrame added in v1.5.0

func (p *Package) AddTrackedFrame(frame *tracked.TrackerWrapperPacket)

func (*Package) SortShapes

func (p *Package) SortShapes()

type Path

type Path struct {
	D []PathElement `json:"d"`
	Style
	Metadata
}

type PathElement

type PathElement struct {
	Type string    `json:"type"`
	Args []float64 `json:"args"`
}

type Point

type Point struct {
	X float32 `json:"x"`
	Y float32 `json:"y"`
}

type PublishType added in v1.5.0

type PublishType int

type Publisher

type Publisher struct {
	DetectionProvider   func() *vision.SSL_DetectionFrame
	TrackerProvider     func() map[string]*tracked.TrackerWrapperPacket
	GeometryProvider    func() *vision.SSL_GeometryData
	LineSegmentProvider func() map[string][]*visualization.LineSegment
	CircleProvider      func() map[string][]*visualization.Circle
	// contains filtered or unexported fields
}

func NewPublisher

func NewPublisher() (p Publisher)

func (*Publisher) Handler

func (p *Publisher) Handler(w http.ResponseWriter, r *http.Request)

type PublisherClient added in v1.5.0

type PublisherClient struct {
	// contains filtered or unexported fields
}

type Request added in v1.5.0

type Request struct {
	ActiveSourceId string `json:"activeSourceId"`
}

type Shape added in v0.3.1

type Shape struct {
	OrderNumber int32   `json:"orderNumber"`
	Line        *Line   `json:"line,omitempty"`
	Circle      *Circle `json:"circle,omitempty"`
	Path        *Path   `json:"path,omitempty"`
	Text        *Text   `json:"text,omitempty"`
}

type ShapesByOrderNumber added in v0.3.1

type ShapesByOrderNumber []Shape

func (ShapesByOrderNumber) Len added in v0.3.1

func (a ShapesByOrderNumber) Len() int

func (ShapesByOrderNumber) Less added in v0.3.1

func (a ShapesByOrderNumber) Less(i, j int) bool

func (ShapesByOrderNumber) Swap added in v0.3.1

func (a ShapesByOrderNumber) Swap(i, j int)

type Style

type Style struct {
	Stroke      *string  `json:"stroke,omitempty"`
	StrokeWidth *float32 `json:"strokeWidth,omitempty"`
	Fill        *string  `json:"fill,omitempty"`
	FillOpacity *float32 `json:"fillOpacity,omitempty"`
	Font        *string  `json:"font,omitempty"`
}

type Text

type Text struct {
	Text string `json:"text"`
	P    Point  `json:"p"`
	Style
	Metadata
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL