fix: serval bugs
This commit is contained in:
@@ -45,21 +45,21 @@ export const useVideoSubtitleEmbedding = async (
|
||||
await videoSprite.ready;
|
||||
|
||||
const srtSprite = new OffscreenSprite(
|
||||
new EmbedSubtitlesClip(await (await fetch(srtUrl)).text(), {
|
||||
new EmbedSubtitlesClip(await(await fetch(srtUrl)).text(), {
|
||||
videoWidth: 1920,
|
||||
videoHeight: 1080,
|
||||
fontSize: 36,
|
||||
fontFamily: "Noto Sans SC",
|
||||
strokeStyle: "none",
|
||||
fontFamily: 'Noto Sans SC',
|
||||
strokeStyle: 'none',
|
||||
textShadow: {
|
||||
offsetX: 2,
|
||||
offsetY: 2,
|
||||
blur: 4,
|
||||
color: "rgba(0, 0, 0, 0.25)",
|
||||
blur: 6,
|
||||
color: 'rgba(0, 0, 0, 0.35)',
|
||||
},
|
||||
...options,
|
||||
})
|
||||
);
|
||||
)
|
||||
await srtSprite.ready;
|
||||
srtSprite.time = { duration: videoClip.meta.duration, offset: 0 }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user