代码拉取完成,页面将自动刷新
抖音、快手、火山小视频等一系列 App使短视频录制已经成功热门的功能。阿里云短视频 SDK、趣拍云 SDK、涂图 SDK、七牛短视频 SDK等市面上的短视频 SDK 均收费昂贵。 看到有人给我 star,请期待我后续更新,把代码抽离出来。
贴纸资源采用zip打包压缩制作,json文件配置,配置格式如下:
{
"fixed_stickers": [
{
"sticker_directory": "flower",
"filename_format": "flower_%zd",
"frame_count": 100,
"positionX": 0.5,
"positionY": 1,
"anchorpointX": 0.5,
"anchorpointY": 1,
"width": 540,
"height": 200,
"animation_duration": 5,
"display_width": 1,
"display_height": 0
}
],
"face_stickers": [
{
"sticker_directory": "cap",
"filename_format": "cap_%zd",
"frame_count": 25,
"face_type": "head",
"width": 330,
"height": 220,
"animation_duration": 3
}
]
}
类型 | 参数名称 | 说明 |
---|---|---|
固定贴纸/人脸贴纸 | sticker_directory | 贴纸资源所在目录 |
固定贴纸/人脸贴纸 | filename_format | 名称格式化 |
固定贴纸/人脸贴纸 | frame_count | 帧数 |
固定贴纸 | positionX | 坐标值x(取值0~1) |
固定贴纸 | positionY | 坐标值y(取值0~1) |
固定贴纸 | anchorpointX | 锚点x(取值0~1) |
固定贴纸 | anchorpointY | 锚点y(取值0~1) |
固定贴纸/人脸贴纸 | width | 贴纸原始宽度 |
固定贴纸/人脸贴纸 | height | 贴纸原始高度 |
固定贴纸 | display_width | 相对屏幕宽度的展示宽度(0为自动) |
固定贴纸 | display_height | 相对屏幕高度的展示高度(0为自动) |
固定贴纸/人脸贴纸 | animation_duration | 完成一次动画的时长 |
人脸贴纸 | face_type | 人脸识别类型(face、nose、head、mouth) |
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。