2021-01-28 09:52:44 -05:00
|
|
|
async function register ({ transcodingManager }) {
|
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
// Output options
|
2021-01-28 09:52:44 -05:00
|
|
|
{
|
2021-04-09 04:36:21 -04:00
|
|
|
{
|
|
|
|
const builder = () => {
|
|
|
|
return {
|
|
|
|
outputOptions: [
|
|
|
|
'-r 10'
|
|
|
|
]
|
|
|
|
}
|
2021-01-28 09:52:44 -05:00
|
|
|
}
|
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
transcodingManager.addVODProfile('libx264', 'low-vod', builder)
|
|
|
|
}
|
2021-01-28 09:52:44 -05:00
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
{
|
|
|
|
const builder = (options) => {
|
|
|
|
return {
|
|
|
|
outputOptions: [
|
2021-07-22 02:46:55 -04:00
|
|
|
'-r:' + options.streamNum + ' 50'
|
2021-04-09 04:36:21 -04:00
|
|
|
]
|
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
}
|
|
|
|
|
2021-07-22 02:46:55 -04:00
|
|
|
transcodingManager.addLiveProfile('libx264', 'high-live', builder)
|
2021-04-09 04:36:21 -04:00
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
}
|
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
// Input options
|
2021-04-06 09:12:38 -04:00
|
|
|
{
|
2021-04-09 04:36:21 -04:00
|
|
|
{
|
|
|
|
const builder = () => {
|
|
|
|
return {
|
|
|
|
inputOptions: [
|
|
|
|
'-r 5'
|
|
|
|
]
|
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
}
|
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
transcodingManager.addVODProfile('libx264', 'input-options-vod', builder)
|
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
{
|
|
|
|
const builder = () => {
|
|
|
|
return {
|
|
|
|
inputOptions: [
|
2021-07-22 02:46:55 -04:00
|
|
|
'-r 50'
|
2021-04-09 04:36:21 -04:00
|
|
|
]
|
|
|
|
}
|
2021-01-28 09:52:44 -05:00
|
|
|
}
|
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
transcodingManager.addLiveProfile('libx264', 'input-options-live', builder)
|
|
|
|
}
|
2021-01-28 09:52:44 -05:00
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
// Scale filters
|
2021-04-06 09:12:38 -04:00
|
|
|
{
|
2021-04-09 04:36:21 -04:00
|
|
|
{
|
|
|
|
const builder = () => {
|
|
|
|
return {
|
|
|
|
scaleFilter: {
|
|
|
|
name: 'Glomgold'
|
|
|
|
}
|
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
}
|
2021-04-09 04:36:21 -04:00
|
|
|
|
|
|
|
transcodingManager.addVODProfile('libx264', 'bad-scale-vod', builder)
|
2021-04-06 09:12:38 -04:00
|
|
|
}
|
|
|
|
|
2021-04-09 04:36:21 -04:00
|
|
|
{
|
|
|
|
const builder = () => {
|
|
|
|
return {
|
|
|
|
scaleFilter: {
|
|
|
|
name: 'Flintheart'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
transcodingManager.addLiveProfile('libx264', 'bad-scale-live', builder)
|
|
|
|
}
|
2021-04-06 09:12:38 -04:00
|
|
|
}
|
2021-01-28 09:52:44 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
async function unregister () {
|
|
|
|
return
|
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
register,
|
|
|
|
unregister
|
|
|
|
}
|