feat: 为MaterialSegmentView添加视频片段缩略图显示功能
This commit is contained in:
parent
0898b4b9e2
commit
70e4acb2c2
|
|
@ -110,7 +110,7 @@ const playVideoSegment = async (filePath: string, startTime: number, endTime: nu
|
||||||
const generateSegmentThumbnail = async (segment: SegmentWithDetails): Promise<string | null> => {
|
const generateSegmentThumbnail = async (segment: SegmentWithDetails): Promise<string | null> => {
|
||||||
try {
|
try {
|
||||||
// 使用片段的开始时间作为缩略图时间戳(首帧)
|
// 使用片段的开始时间作为缩略图时间戳(首帧)
|
||||||
const timestamp = segment.segment.start_time;
|
const timestamp = 0;
|
||||||
|
|
||||||
// 生成缩略图文件名
|
// 生成缩略图文件名
|
||||||
const thumbnailFileName = `${segment.segment.id}_thumbnail.jpg`;
|
const thumbnailFileName = `${segment.segment.id}_thumbnail.jpg`;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue