stream-server/main.go

27 lines
340 B
Go
Raw Normal View History

2023-08-09 16:00:21 +05:00
package main
2023-08-15 14:28:13 +05:00
import "stream_server/rtmp"
2023-08-09 16:00:21 +05:00
const (
SRVTYPE_RTMP uint8 = iota
)
func main() {
err := NewIngestServer(SRVTYPE_RTMP, "7878")
if err != nil {
panic(err)
}
for {
}
}
2023-08-15 14:28:13 +05:00
func NewIngestServer(srvr_type uint8, port string) (error) {
var err error
switch srvr_type {
case 0:
err = rtmp.NewServer(&port)
}
return err
}