@evio/ffai 1.0.3 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/lib.js +7 -7
  2. package/package.json +1 -1
package/dist/lib.js CHANGED
@@ -230,15 +230,15 @@ function addSubTitles(inputfile, outputfile, texts, fontfile) {
230
230
  options: {
231
231
  fontfile,
232
232
  text: e.text,
233
- fontsize: 36, // 增大字体大小,确保清晰可见
233
+ fontsize: 36, // 字体大小
234
234
  fontcolor: "white", // 文字颜色设置为白色
235
- box: 1, // 启用背景框
236
- boxcolor: "black@0.7", // 半透明黑色背景,使用ffmpeg支持的格式
237
- boxborderw: 4, // 调整边框宽度
238
- // max_width: "w*0.8", // 最大宽度为视频宽度的80%,超过则自动换行
239
- // line_spacing: 8, // 行间距为8像素
235
+ shadowcolor: "black@0.8", // 阴影颜色:黑色,透明度 0.8
236
+ shadowx: 2, // 阴影 X 轴偏移
237
+ shadowy: 2, // 阴影 Y 轴偏移
238
+ borderw: 2, // 文字边框宽度,创建渐变效果
239
+ bordercolor: "black@0.6", // 边框颜色:黑色,透明度 0.6
240
240
  x: "(w-text_w)/2", // 水平居中
241
- y: "(h-text_h-300)", // 底部以上100像素的位置,确保在视频范围内
241
+ y: "(h-text_h-300)", // 底部以上 300 像素的位置
242
242
  enable: `between(t,${e.start},${e.end})`,
243
243
  },
244
244
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@evio/ffai",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "一个基于 FFmpeg 的命令行工具,用于批量处理视频和音频文件,支持视频转码、音频合并、字幕添加等功能。",
5
5
  "main": "dist/lib.js",
6
6
  "scripts": {