mirror of
https://github.com/datarhei/core.git
synced 2025-09-26 20:11:29 +08:00
Add looping_runtime to avstream status
This commit is contained in:
35
docs/docs.go
35
docs/docs.go
@@ -2032,6 +2032,10 @@ const docTemplate = `{
|
|||||||
"looping": {
|
"looping": {
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
},
|
},
|
||||||
|
"looping_runtime": {
|
||||||
|
"type": "integer",
|
||||||
|
"format": "uint64"
|
||||||
|
},
|
||||||
"output": {
|
"output": {
|
||||||
"$ref": "#/definitions/api.AVstreamIO"
|
"$ref": "#/definitions/api.AVstreamIO"
|
||||||
},
|
},
|
||||||
@@ -3044,6 +3048,10 @@ const docTemplate = `{
|
|||||||
},
|
},
|
||||||
"type": {
|
"type": {
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
},
|
||||||
|
"updated_at": {
|
||||||
|
"type": "integer",
|
||||||
|
"format": "int64"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -3358,18 +3366,7 @@ const docTemplate = `{
|
|||||||
"format": "uint64"
|
"format": "uint64"
|
||||||
},
|
},
|
||||||
"framerate": {
|
"framerate": {
|
||||||
"type": "object",
|
"$ref": "#/definitions/api.ProgressIOFramerate"
|
||||||
"properties": {
|
|
||||||
"avg": {
|
|
||||||
"type": "number"
|
|
||||||
},
|
|
||||||
"max": {
|
|
||||||
"type": "number"
|
|
||||||
},
|
|
||||||
"min": {
|
|
||||||
"type": "number"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"height": {
|
"height": {
|
||||||
"type": "integer",
|
"type": "integer",
|
||||||
@@ -3427,6 +3424,20 @@ const docTemplate = `{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"api.ProgressIOFramerate": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"avg": {
|
||||||
|
"type": "number"
|
||||||
|
},
|
||||||
|
"max": {
|
||||||
|
"type": "number"
|
||||||
|
},
|
||||||
|
"min": {
|
||||||
|
"type": "number"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"api.RTMPChannel": {
|
"api.RTMPChannel": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
@@ -2025,6 +2025,10 @@
|
|||||||
"looping": {
|
"looping": {
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
},
|
},
|
||||||
|
"looping_runtime": {
|
||||||
|
"type": "integer",
|
||||||
|
"format": "uint64"
|
||||||
|
},
|
||||||
"output": {
|
"output": {
|
||||||
"$ref": "#/definitions/api.AVstreamIO"
|
"$ref": "#/definitions/api.AVstreamIO"
|
||||||
},
|
},
|
||||||
@@ -3037,6 +3041,10 @@
|
|||||||
},
|
},
|
||||||
"type": {
|
"type": {
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
},
|
||||||
|
"updated_at": {
|
||||||
|
"type": "integer",
|
||||||
|
"format": "int64"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -3351,18 +3359,7 @@
|
|||||||
"format": "uint64"
|
"format": "uint64"
|
||||||
},
|
},
|
||||||
"framerate": {
|
"framerate": {
|
||||||
"type": "object",
|
"$ref": "#/definitions/api.ProgressIOFramerate"
|
||||||
"properties": {
|
|
||||||
"avg": {
|
|
||||||
"type": "number"
|
|
||||||
},
|
|
||||||
"max": {
|
|
||||||
"type": "number"
|
|
||||||
},
|
|
||||||
"min": {
|
|
||||||
"type": "number"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
"height": {
|
"height": {
|
||||||
"type": "integer",
|
"type": "integer",
|
||||||
@@ -3420,6 +3417,20 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"api.ProgressIOFramerate": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"avg": {
|
||||||
|
"type": "number"
|
||||||
|
},
|
||||||
|
"max": {
|
||||||
|
"type": "number"
|
||||||
|
},
|
||||||
|
"min": {
|
||||||
|
"type": "number"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"api.RTMPChannel": {
|
"api.RTMPChannel": {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
|
@@ -22,6 +22,9 @@ definitions:
|
|||||||
$ref: '#/definitions/api.AVstreamIO'
|
$ref: '#/definitions/api.AVstreamIO'
|
||||||
looping:
|
looping:
|
||||||
type: boolean
|
type: boolean
|
||||||
|
looping_runtime:
|
||||||
|
format: uint64
|
||||||
|
type: integer
|
||||||
output:
|
output:
|
||||||
$ref: '#/definitions/api.AVstreamIO'
|
$ref: '#/definitions/api.AVstreamIO'
|
||||||
queue:
|
queue:
|
||||||
@@ -701,6 +704,9 @@ definitions:
|
|||||||
$ref: '#/definitions/api.ProcessState'
|
$ref: '#/definitions/api.ProcessState'
|
||||||
type:
|
type:
|
||||||
type: string
|
type: string
|
||||||
|
updated_at:
|
||||||
|
format: int64
|
||||||
|
type: integer
|
||||||
type: object
|
type: object
|
||||||
api.ProcessConfig:
|
api.ProcessConfig:
|
||||||
properties:
|
properties:
|
||||||
@@ -914,14 +920,7 @@ definitions:
|
|||||||
format: uint64
|
format: uint64
|
||||||
type: integer
|
type: integer
|
||||||
framerate:
|
framerate:
|
||||||
properties:
|
$ref: '#/definitions/api.ProgressIOFramerate'
|
||||||
avg:
|
|
||||||
type: number
|
|
||||||
max:
|
|
||||||
type: number
|
|
||||||
min:
|
|
||||||
type: number
|
|
||||||
type: object
|
|
||||||
height:
|
height:
|
||||||
format: uint64
|
format: uint64
|
||||||
type: integer
|
type: integer
|
||||||
@@ -963,6 +962,15 @@ definitions:
|
|||||||
format: uint64
|
format: uint64
|
||||||
type: integer
|
type: integer
|
||||||
type: object
|
type: object
|
||||||
|
api.ProgressIOFramerate:
|
||||||
|
properties:
|
||||||
|
avg:
|
||||||
|
type: number
|
||||||
|
max:
|
||||||
|
type: number
|
||||||
|
min:
|
||||||
|
type: number
|
||||||
|
type: object
|
||||||
api.RTMPChannel:
|
api.RTMPChannel:
|
||||||
properties:
|
properties:
|
||||||
name:
|
name:
|
||||||
|
@@ -59,33 +59,35 @@ func (avio *ffmpegAVstreamIO) export() app.AVstreamIO {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ffmpegAVstream struct {
|
type ffmpegAVstream struct {
|
||||||
Input ffmpegAVstreamIO `json:"input"`
|
Input ffmpegAVstreamIO `json:"input"`
|
||||||
Output ffmpegAVstreamIO `json:"output"`
|
Output ffmpegAVstreamIO `json:"output"`
|
||||||
Address string `json:"id"`
|
Address string `json:"id"`
|
||||||
URL string `json:"url"`
|
URL string `json:"url"`
|
||||||
Stream uint64 `json:"stream"`
|
Stream uint64 `json:"stream"`
|
||||||
Aqueue uint64 `json:"aqueue"`
|
Aqueue uint64 `json:"aqueue"`
|
||||||
Queue uint64 `json:"queue"`
|
Queue uint64 `json:"queue"`
|
||||||
Dup uint64 `json:"dup"`
|
Dup uint64 `json:"dup"`
|
||||||
Drop uint64 `json:"drop"`
|
Drop uint64 `json:"drop"`
|
||||||
Enc uint64 `json:"enc"`
|
Enc uint64 `json:"enc"`
|
||||||
Looping bool `json:"looping"`
|
Looping bool `json:"looping"`
|
||||||
Duplicating bool `json:"duplicating"`
|
LoopingRuntime uint64 `json:"looping_runtime"`
|
||||||
GOP string `json:"gop"`
|
Duplicating bool `json:"duplicating"`
|
||||||
|
GOP string `json:"gop"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (av *ffmpegAVstream) export() *app.AVstream {
|
func (av *ffmpegAVstream) export() *app.AVstream {
|
||||||
return &app.AVstream{
|
return &app.AVstream{
|
||||||
Aqueue: av.Aqueue,
|
Aqueue: av.Aqueue,
|
||||||
Queue: av.Queue,
|
Queue: av.Queue,
|
||||||
Drop: av.Drop,
|
Drop: av.Drop,
|
||||||
Dup: av.Dup,
|
Dup: av.Dup,
|
||||||
Enc: av.Enc,
|
Enc: av.Enc,
|
||||||
Looping: av.Looping,
|
Looping: av.Looping,
|
||||||
Duplicating: av.Duplicating,
|
LoopingRuntime: av.LoopingRuntime,
|
||||||
GOP: av.GOP,
|
Duplicating: av.Duplicating,
|
||||||
Input: av.Input.export(),
|
GOP: av.GOP,
|
||||||
Output: av.Output.export(),
|
Input: av.Input.export(),
|
||||||
|
Output: av.Output.export(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -23,16 +23,17 @@ func (i *AVstreamIO) Unmarshal(io *app.AVstreamIO) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type AVstream struct {
|
type AVstream struct {
|
||||||
Input AVstreamIO `json:"input"`
|
Input AVstreamIO `json:"input"`
|
||||||
Output AVstreamIO `json:"output"`
|
Output AVstreamIO `json:"output"`
|
||||||
Aqueue uint64 `json:"aqueue" format:"uint64"`
|
Aqueue uint64 `json:"aqueue" format:"uint64"`
|
||||||
Queue uint64 `json:"queue" format:"uint64"`
|
Queue uint64 `json:"queue" format:"uint64"`
|
||||||
Dup uint64 `json:"dup" format:"uint64"`
|
Dup uint64 `json:"dup" format:"uint64"`
|
||||||
Drop uint64 `json:"drop" format:"uint64"`
|
Drop uint64 `json:"drop" format:"uint64"`
|
||||||
Enc uint64 `json:"enc" format:"uint64"`
|
Enc uint64 `json:"enc" format:"uint64"`
|
||||||
Looping bool `json:"looping"`
|
Looping bool `json:"looping"`
|
||||||
Duplicating bool `json:"duplicating"`
|
LoopingRuntime uint64 `json:"looping_runtime" format:"uint64"`
|
||||||
GOP string `json:"gop"`
|
Duplicating bool `json:"duplicating"`
|
||||||
|
GOP string `json:"gop"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *AVstream) Unmarshal(av *app.AVstream) {
|
func (a *AVstream) Unmarshal(av *app.AVstream) {
|
||||||
@@ -46,6 +47,7 @@ func (a *AVstream) Unmarshal(av *app.AVstream) {
|
|||||||
a.Drop = av.Drop
|
a.Drop = av.Drop
|
||||||
a.Enc = av.Enc
|
a.Enc = av.Enc
|
||||||
a.Looping = av.Looping
|
a.Looping = av.Looping
|
||||||
|
a.LoopingRuntime = av.LoopingRuntime
|
||||||
a.Duplicating = av.Duplicating
|
a.Duplicating = av.Duplicating
|
||||||
a.GOP = av.GOP
|
a.GOP = av.GOP
|
||||||
|
|
||||||
|
@@ -3,19 +3,20 @@ package app
|
|||||||
type AVstreamIO struct {
|
type AVstreamIO struct {
|
||||||
State string
|
State string
|
||||||
Packet uint64 // counter
|
Packet uint64 // counter
|
||||||
Time uint64
|
Time uint64 // sec
|
||||||
Size uint64 // bytes
|
Size uint64 // bytes
|
||||||
}
|
}
|
||||||
|
|
||||||
type AVstream struct {
|
type AVstream struct {
|
||||||
Input AVstreamIO
|
Input AVstreamIO
|
||||||
Output AVstreamIO
|
Output AVstreamIO
|
||||||
Aqueue uint64 // gauge
|
Aqueue uint64 // gauge
|
||||||
Queue uint64 // gauge
|
Queue uint64 // gauge
|
||||||
Dup uint64 // counter
|
Dup uint64 // counter
|
||||||
Drop uint64 // counter
|
Drop uint64 // counter
|
||||||
Enc uint64 // counter
|
Enc uint64 // counter
|
||||||
Looping bool
|
Looping bool
|
||||||
Duplicating bool
|
LoopingRuntime uint64 // sec
|
||||||
GOP string
|
Duplicating bool
|
||||||
|
GOP string
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user