handlers

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2021 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package handlers include server handlers

Index

Constants

View Source
const (
	// DetectMinSize default min size for detection
	DetectMinSize int = 20
	// StrokeWidth default strokeWidth
	StrokeWidth float64 = 2
	// TextColor default text color for detection
	TextColor = "#FFF"
	// SuccessColor default success color for detection
	SuccessColor = "#4CAF50"
	// FailedColor default failed color for detection
	FailedColor = "#F44336"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type HTML

type HTML struct {
	Width    float64
	Height   float64
	UseWebGL bool
}

HTML handler.

func NewHTML

func NewHTML(width, height float64, useWebGL bool) *HTML

NewHTML returns new HTML handler.

func (*HTML) ServeHTTP

func (h *HTML) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP handles requests on incoming connections.

type Index

type Index struct {
}

Index handler.

func NewIndex

func NewIndex() *Index

NewIndex returns new Index handler.

func (*Index) ServeHTTP

func (s *Index) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP handles requests on incoming connections.

type JPEG

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

JPEG handler.

func NewJPEG

func NewJPEG(e *openpose.PoseEstimator, cam *camera.Camera) *JPEG

NewJPEG returns new JPEG handler.

func (*JPEG) ServeHTTP

func (s *JPEG) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP handles requests on incoming connections.

type MJPEG

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

MJPEG handler.

func NewMJPEG

func NewMJPEG(e *openpose.PoseEstimator, cam *camera.Camera, delay int) *MJPEG

NewMJPEG returns new MJPEG handler.

func (*MJPEG) ServeHTTP

func (s *MJPEG) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP handles requests on incoming connections.

type Socket

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

Socket handler.

func NewSocket

func NewSocket(e *openpose.PoseEstimator, cam *camera.Camera, delay int) *Socket

NewSocket returns new socket handler.

func (*Socket) ServeHTTP

func (s *Socket) ServeHTTP(w http.ResponseWriter, r *http.Request)

ServeHTTP handles requests on incoming connections.

Jump to

Keyboard shortcuts

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