visualization

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2021 License: GPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Circle

type Circle struct {
	// The metadata
	Metadata *Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// Center point, x value [m]
	CenterX float32 `protobuf:"fixed32,2,opt,name=center_x,json=centerX,proto3" json:"center_x,omitempty"`
	// Center point, y value [m]
	CenterY float32 `protobuf:"fixed32,3,opt,name=center_y,json=centerY,proto3" json:"center_y,omitempty"`
	// Radius [m]
	Radius               float32  `protobuf:"fixed32,4,opt,name=radius,proto3" json:"radius,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

A full circle

func (*Circle) Descriptor

func (*Circle) Descriptor() ([]byte, []int)

func (*Circle) GetCenterX

func (m *Circle) GetCenterX() float32

func (*Circle) GetCenterY

func (m *Circle) GetCenterY() float32

func (*Circle) GetMetadata

func (m *Circle) GetMetadata() *Metadata

func (*Circle) GetRadius

func (m *Circle) GetRadius() float32

func (*Circle) ProtoMessage

func (*Circle) ProtoMessage()

func (*Circle) Reset

func (m *Circle) Reset()

func (*Circle) String

func (m *Circle) String() string

func (*Circle) XXX_DiscardUnknown

func (m *Circle) XXX_DiscardUnknown()

func (*Circle) XXX_Marshal

func (m *Circle) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Circle) XXX_Merge

func (m *Circle) XXX_Merge(src proto.Message)

func (*Circle) XXX_Size

func (m *Circle) XXX_Size() int

func (*Circle) XXX_Unmarshal

func (m *Circle) XXX_Unmarshal(b []byte) error

type LineSegment

type LineSegment struct {
	// The metadata
	Metadata *Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"`
	// Start point, x value [m]
	StartX float32 `protobuf:"fixed32,2,opt,name=start_x,json=startX,proto3" json:"start_x,omitempty"`
	// Start point, y value [m]
	StartY float32 `protobuf:"fixed32,3,opt,name=start_y,json=startY,proto3" json:"start_y,omitempty"`
	// End point, x value [m]
	EndX float32 `protobuf:"fixed32,4,opt,name=end_x,json=endX,proto3" json:"end_x,omitempty"`
	// End point, y value [m]
	EndY                 float32  `protobuf:"fixed32,5,opt,name=end_y,json=endY,proto3" json:"end_y,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

A line segment

func (*LineSegment) Descriptor

func (*LineSegment) Descriptor() ([]byte, []int)

func (*LineSegment) GetEndX

func (m *LineSegment) GetEndX() float32

func (*LineSegment) GetEndY

func (m *LineSegment) GetEndY() float32

func (*LineSegment) GetMetadata

func (m *LineSegment) GetMetadata() *Metadata

func (*LineSegment) GetStartX

func (m *LineSegment) GetStartX() float32

func (*LineSegment) GetStartY

func (m *LineSegment) GetStartY() float32

func (*LineSegment) ProtoMessage

func (*LineSegment) ProtoMessage()

func (*LineSegment) Reset

func (m *LineSegment) Reset()

func (*LineSegment) String

func (m *LineSegment) String() string

func (*LineSegment) XXX_DiscardUnknown

func (m *LineSegment) XXX_DiscardUnknown()

func (*LineSegment) XXX_Marshal

func (m *LineSegment) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*LineSegment) XXX_Merge

func (m *LineSegment) XXX_Merge(src proto.Message)

func (*LineSegment) XXX_Size

func (m *LineSegment) XXX_Size() int

func (*LineSegment) XXX_Unmarshal

func (m *LineSegment) XXX_Unmarshal(b []byte) error

type Metadata

type Metadata struct {
	// layer name, optionally with a hierarchy
	Layer []string `protobuf:"bytes,1,rep,name=layer,proto3" json:"layer,omitempty"`
	// Should a client show this by default?
	VisibleByDefault bool `protobuf:"varint,2,opt,name=visibleByDefault,proto3" json:"visibleByDefault,omitempty"`
	// An order number:
	// <0: Below field lines
	// 0: default
	// 1: robots
	// 2: robot ids
	// 3: ball
	// >3: above vision objects
	Order int32 `protobuf:"varint,3,opt,name=order,proto3" json:"order,omitempty"`
	// Color to fill the shape
	ColorFill *RgbColor `protobuf:"bytes,4,opt,name=color_fill,json=colorFill,proto3" json:"color_fill,omitempty"`
	// Color for the shape stroke
	ColorStroke          *RgbColor `protobuf:"bytes,5,opt,name=color_stroke,json=colorStroke,proto3" json:"color_stroke,omitempty"`
	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
	XXX_unrecognized     []byte    `json:"-"`
	XXX_sizecache        int32     `json:"-"`
}

Metadata for each shape

func (*Metadata) Descriptor

func (*Metadata) Descriptor() ([]byte, []int)

func (*Metadata) GetColorFill

func (m *Metadata) GetColorFill() *RgbColor

func (*Metadata) GetColorStroke

func (m *Metadata) GetColorStroke() *RgbColor

func (*Metadata) GetLayer

func (m *Metadata) GetLayer() []string

func (*Metadata) GetOrder

func (m *Metadata) GetOrder() int32

func (*Metadata) GetVisibleByDefault

func (m *Metadata) GetVisibleByDefault() bool

func (*Metadata) ProtoMessage

func (*Metadata) ProtoMessage()

func (*Metadata) Reset

func (m *Metadata) Reset()

func (*Metadata) String

func (m *Metadata) String() string

func (*Metadata) XXX_DiscardUnknown

func (m *Metadata) XXX_DiscardUnknown()

func (*Metadata) XXX_Marshal

func (m *Metadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Metadata) XXX_Merge

func (m *Metadata) XXX_Merge(src proto.Message)

func (*Metadata) XXX_Size

func (m *Metadata) XXX_Size() int

func (*Metadata) XXX_Unmarshal

func (m *Metadata) XXX_Unmarshal(b []byte) error

type Publisher

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

func NewPublisher

func NewPublisher(address string) (publisher Publisher)

func (*Publisher) Send

func (p *Publisher) Send(frame *VisualizationFrame)

type RgbColor

type RgbColor struct {
	// red (0-255)
	R uint32 `protobuf:"varint,1,opt,name=r,proto3" json:"r,omitempty"`
	// green (0-255)
	G uint32 `protobuf:"varint,2,opt,name=g,proto3" json:"g,omitempty"`
	// blue (0-255)
	B uint32 `protobuf:"varint,3,opt,name=b,proto3" json:"b,omitempty"`
	// alpha (0.0-1.0)
	A                    float32  `protobuf:"fixed32,4,opt,name=a,proto3" json:"a,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

Color encoded in RGB

func (*RgbColor) Descriptor

func (*RgbColor) Descriptor() ([]byte, []int)

func (*RgbColor) GetA

func (m *RgbColor) GetA() float32

func (*RgbColor) GetB

func (m *RgbColor) GetB() uint32

func (*RgbColor) GetG

func (m *RgbColor) GetG() uint32

func (*RgbColor) GetR

func (m *RgbColor) GetR() uint32

func (*RgbColor) ProtoMessage

func (*RgbColor) ProtoMessage()

func (*RgbColor) Reset

func (m *RgbColor) Reset()

func (*RgbColor) String

func (m *RgbColor) String() string

func (*RgbColor) XXX_DiscardUnknown

func (m *RgbColor) XXX_DiscardUnknown()

func (*RgbColor) XXX_Marshal

func (m *RgbColor) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RgbColor) XXX_Merge

func (m *RgbColor) XXX_Merge(src proto.Message)

func (*RgbColor) XXX_Size

func (m *RgbColor) XXX_Size() int

func (*RgbColor) XXX_Unmarshal

func (m *RgbColor) XXX_Unmarshal(b []byte) error

type VisualizationFrame

type VisualizationFrame struct {
	// An identifier for the sender
	// Used to identify the source of shapes in a client
	// Also used to keep track of the latest frame of each sender in clients, if there a multiple ones senders
	SenderId string `protobuf:"bytes,1,opt,name=sender_id,json=senderId,proto3" json:"sender_id,omitempty"`
	// all lines
	Lines []*LineSegment `protobuf:"bytes,2,rep,name=lines,proto3" json:"lines,omitempty"`
	// all circles
	Circles              []*Circle `protobuf:"bytes,3,rep,name=circles,proto3" json:"circles,omitempty"`
	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
	XXX_unrecognized     []byte    `json:"-"`
	XXX_sizecache        int32     `json:"-"`
}

Wrapper frame containing all shapes

func (*VisualizationFrame) Descriptor

func (*VisualizationFrame) Descriptor() ([]byte, []int)

func (*VisualizationFrame) GetCircles

func (m *VisualizationFrame) GetCircles() []*Circle

func (*VisualizationFrame) GetLines

func (m *VisualizationFrame) GetLines() []*LineSegment

func (*VisualizationFrame) GetSenderId

func (m *VisualizationFrame) GetSenderId() string

func (*VisualizationFrame) ProtoMessage

func (*VisualizationFrame) ProtoMessage()

func (*VisualizationFrame) Reset

func (m *VisualizationFrame) Reset()

func (*VisualizationFrame) String

func (m *VisualizationFrame) String() string

func (*VisualizationFrame) XXX_DiscardUnknown

func (m *VisualizationFrame) XXX_DiscardUnknown()

func (*VisualizationFrame) XXX_Marshal

func (m *VisualizationFrame) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*VisualizationFrame) XXX_Merge

func (m *VisualizationFrame) XXX_Merge(src proto.Message)

func (*VisualizationFrame) XXX_Size

func (m *VisualizationFrame) XXX_Size() int

func (*VisualizationFrame) XXX_Unmarshal

func (m *VisualizationFrame) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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