server

package
v0.0.0-...-51c8454 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Overview

Package server contains a simple MJPEG stream web server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

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

Server is a simple MJPEG HTTP streaming server. Use NewServer to initiate an instance.

func NewServer

func NewServer(embed bool) (*Server, error)

NewServer creates a new server.

func (*Server) GetMux

func (s *Server) GetMux() *http.ServeMux

GetMux returns the router.

func (*Server) SetFrame

func (s *Server) SetFrame(frame image.Image) error

SetFrame encodes an image as JPEG and streams it.

func (*Server) SetFrameRawJPEG

func (s *Server) SetFrameRawJPEG(frame []byte) error

SetFrameRawJPEG streams a raw encoded JPEG frame.

Jump to

Keyboard shortcuts

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