MCPcopy
hub / github.com/simstudioai/sim / convert

Function convert

apps/sim/lib/media/ffmpeg.ts:548–558  ·  view source on GitHub ↗
(
  dir: string,
  inputPath: string,
  options: FfmpegOptions
)

Source from the content-addressed store, hash-verified

546}
547
548async function convert(
549 dir: string,
550 inputPath: string,
551 options: FfmpegOptions
552): Promise<FfmpegResult> {
553 if (!options.format) throw new Error('convert requires a target format')
554 const ext = options.format.toLowerCase()
555 const outputPath = path.join(dir, `out.${ext}`)
556 await runCommand(ffmpeg(inputPath), outputPath)
557 return readOut(outputPath, ext)
558}
559
560async function thumbnail(
561 dir: string,

Callers 3

htmlToPlainTextFunction · 0.85
runFfmpegOperationFunction · 0.85
route.tsFile · 0.85

Calls 3

readOutFunction · 0.85
joinMethod · 0.80
runCommandFunction · 0.70

Tested by

no test coverage detected