Skip to content

Commit 381aa14

Browse files
committed
feat: Refactor part of the code
1 parent 46aeff3 commit 381aa14

File tree

4 files changed

+5
-4
lines changed

4 files changed

+5
-4
lines changed

examples/live.js

+1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ const createFFTask = () => {
2828
height,
2929
log: true,
3030
preset: 'veryfast',
31+
vprofile: 'baseline',
3132
pushLive: true,
3233
audio,
3334
});

lib/conf/conf.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class Conf {
2525
this.copyByDefaultVal(conf, 'queue', 2);
2626
this.copyByDefaultVal(conf, 'threads', 1);
2727
this.copyByDefaultVal(conf, 'preset', 'medium');
28-
this.copyByDefaultVal(conf, 'vprofile', 'baseline');
28+
this.copyByDefaultVal(conf, 'vprofile', 'main');
2929
this.copyByDefaultVal(conf, 'debug', false);
3030
this.copyByDefaultVal(conf, 'audioLoop', true);
3131
this.copyByDefaultVal(conf, 'pushLive', false);

lib/utils/ffmpeg.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ const FFmpegUtil = {
7777
const crf = conf.getVal('crf');
7878
const preset = conf.getVal('preset');
7979
const vprofile = conf.getVal('vprofile');
80-
const pushLIve = conf.getVal('pushLive');
80+
const pushLive = conf.getVal('pushLive');
8181

8282
let outputOptions = []
8383
//---- misc ----
@@ -118,7 +118,7 @@ const FFmpegUtil = {
118118
}
119119

120120
//---- live stream ----
121-
if (!pushLIve) {
121+
if (!pushLive) {
122122
outputOptions = outputOptions.concat(['-map', '0']);
123123
}
124124

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ffcreatorlite",
3-
"version": "2.3.2",
3+
"version": "2.3.5",
44
"description": "FFCreatorLite is a lightweight and flexible short video production library",
55
"main": "lib/index.js",
66
"scripts": {

0 commit comments

Comments
 (0)