mirror of
https://github.com/lkmio/lkm.git
synced 2025-09-27 11:32:26 +08:00
项目更名为lkm
This commit is contained in:
12
api.go
12
api.go
@@ -6,12 +6,12 @@ import (
|
|||||||
"github.com/gorilla/mux"
|
"github.com/gorilla/mux"
|
||||||
"github.com/gorilla/websocket"
|
"github.com/gorilla/websocket"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/flv"
|
"github.com/yangjiechina/lkm/flv"
|
||||||
"github.com/yangjiechina/live-server/gb28181"
|
"github.com/yangjiechina/lkm/gb28181"
|
||||||
"github.com/yangjiechina/live-server/hls"
|
"github.com/yangjiechina/lkm/hls"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/rtc"
|
"github.com/yangjiechina/lkm/rtc"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"io"
|
"io"
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
package flv
|
package flv
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/avformat/libflv"
|
"github.com/yangjiechina/avformat/libflv"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
@@ -2,7 +2,7 @@ package gb28181
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/pion/rtp"
|
"github.com/pion/rtp"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -9,8 +9,8 @@ import (
|
|||||||
"github.com/yangjiechina/avformat/libmpeg"
|
"github.com/yangjiechina/avformat/libmpeg"
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -2,7 +2,7 @@ package gb28181
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/pion/rtp"
|
"github.com/pion/rtp"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
type PassiveSource struct {
|
type PassiveSource struct {
|
||||||
|
@@ -3,8 +3,8 @@ package gb28181
|
|||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/pion/rtp"
|
"github.com/pion/rtp"
|
||||||
"github.com/yangjiechina/live-server/jitterbuffer"
|
"github.com/yangjiechina/lkm/jitterbuffer"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
type UDPSource struct {
|
type UDPSource struct {
|
||||||
|
@@ -3,7 +3,7 @@ package gb28181
|
|||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -2,7 +2,7 @@ package gb28181
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
2
go.mod
2
go.mod
@@ -1,4 +1,4 @@
|
|||||||
module github.com/yangjiechina/live-server
|
module github.com/yangjiechina/lkm
|
||||||
|
|
||||||
require github.com/yangjiechina/avformat v0.0.0
|
require github.com/yangjiechina/avformat v0.0.0
|
||||||
|
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
package hls
|
package hls
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
type tsSink struct {
|
type tsSink struct {
|
||||||
|
@@ -4,7 +4,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/avformat/libmpeg"
|
"github.com/yangjiechina/avformat/libmpeg"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"os"
|
"os"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -2,7 +2,7 @@ package hls
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"math"
|
"math"
|
||||||
"strconv"
|
"strconv"
|
||||||
)
|
)
|
||||||
|
@@ -3,8 +3,8 @@ package jt1078
|
|||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -5,8 +5,8 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
18
main.go
18
main.go
@@ -2,21 +2,21 @@ package main
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/live-server/flv"
|
"github.com/yangjiechina/lkm/flv"
|
||||||
"github.com/yangjiechina/live-server/gb28181"
|
"github.com/yangjiechina/lkm/gb28181"
|
||||||
"github.com/yangjiechina/live-server/hls"
|
"github.com/yangjiechina/lkm/hls"
|
||||||
"github.com/yangjiechina/live-server/jt1078"
|
"github.com/yangjiechina/lkm/jt1078"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/rtc"
|
"github.com/yangjiechina/lkm/rtc"
|
||||||
"github.com/yangjiechina/live-server/rtsp"
|
"github.com/yangjiechina/lkm/rtsp"
|
||||||
"go.uber.org/zap/zapcore"
|
"go.uber.org/zap/zapcore"
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
|
||||||
_ "net/http/pprof"
|
_ "net/http/pprof"
|
||||||
|
|
||||||
"github.com/yangjiechina/live-server/rtmp"
|
"github.com/yangjiechina/lkm/rtmp"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
func NewDefaultAppConfig() stream.AppConfig_ {
|
func NewDefaultAppConfig() stream.AppConfig_ {
|
||||||
|
@@ -3,7 +3,7 @@ package rtc
|
|||||||
import (
|
import (
|
||||||
"github.com/pion/webrtc/v3"
|
"github.com/pion/webrtc/v3"
|
||||||
"github.com/pion/webrtc/v3/pkg/media"
|
"github.com/pion/webrtc/v3/pkg/media"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -3,7 +3,7 @@ package rtc
|
|||||||
import (
|
import (
|
||||||
"github.com/pion/webrtc/v3"
|
"github.com/pion/webrtc/v3"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
type transStream struct {
|
type transStream struct {
|
||||||
|
@@ -5,7 +5,7 @@ import (
|
|||||||
"github.com/yangjiechina/avformat/librtmp"
|
"github.com/yangjiechina/avformat/librtmp"
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
package rtmp
|
package rtmp
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"net"
|
"net"
|
||||||
|
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
|
@@ -3,7 +3,7 @@ package rtmp
|
|||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/librtmp"
|
"github.com/yangjiechina/avformat/librtmp"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
"testing"
|
"testing"
|
||||||
)
|
)
|
||||||
|
@@ -3,8 +3,8 @@ package rtmp
|
|||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/librtmp"
|
"github.com/yangjiechina/avformat/librtmp"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -2,7 +2,7 @@ package rtmp
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -4,7 +4,7 @@ import (
|
|||||||
"github.com/yangjiechina/avformat/libflv"
|
"github.com/yangjiechina/avformat/libflv"
|
||||||
"github.com/yangjiechina/avformat/librtmp"
|
"github.com/yangjiechina/avformat/librtmp"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
)
|
)
|
||||||
|
|
||||||
type TransStream struct {
|
type TransStream struct {
|
||||||
|
@@ -3,8 +3,8 @@ package rtsp
|
|||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net/http"
|
"net/http"
|
||||||
"net/textproto"
|
"net/textproto"
|
||||||
"net/url"
|
"net/url"
|
||||||
|
@@ -3,7 +3,7 @@ package rtsp
|
|||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"net"
|
"net"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -6,8 +6,8 @@ import (
|
|||||||
"github.com/yangjiechina/avformat/librtp"
|
"github.com/yangjiechina/avformat/librtp"
|
||||||
"github.com/yangjiechina/avformat/transport"
|
"github.com/yangjiechina/avformat/transport"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
@@ -8,7 +8,7 @@ import (
|
|||||||
"github.com/yangjiechina/avformat/librtp"
|
"github.com/yangjiechina/avformat/librtp"
|
||||||
"github.com/yangjiechina/avformat/librtsp/sdp"
|
"github.com/yangjiechina/avformat/librtsp/sdp"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/stream"
|
"github.com/yangjiechina/lkm/stream"
|
||||||
"net"
|
"net"
|
||||||
"strconv"
|
"strconv"
|
||||||
)
|
)
|
||||||
|
@@ -2,7 +2,7 @@ package stream
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"net/http"
|
"net/http"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -2,14 +2,14 @@ package stream
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/yangjiechina/live-server/log"
|
"github.com/yangjiechina/lkm/log"
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/yangjiechina/avformat/stream"
|
"github.com/yangjiechina/avformat/stream"
|
||||||
"github.com/yangjiechina/avformat/utils"
|
"github.com/yangjiechina/avformat/utils"
|
||||||
"github.com/yangjiechina/live-server/transcode"
|
"github.com/yangjiechina/lkm/transcode"
|
||||||
)
|
)
|
||||||
|
|
||||||
// SourceType 推流类型
|
// SourceType 推流类型
|
||||||
|
Reference in New Issue
Block a user