@ozean/set-webm-duration
TypeScript icon, indicating that this package has built-in type declarations

0.1.3 • Public • Published

Set Webm Duration

write duration into webm blob

import { setWebmDuration } from '@ozean/set-webm-duration'

const webmBuffer = await webmBlob.arrayBuffer()

const newWebmBuffer = setWebmDuration(webmBuffer, 45296 * 1000)

const newWebmBlob = new Blob([newWebmBuffer])

document.querySelector("audio")!.src = URL.createObjectURL(newWebmBlob)

/@ozean/set-webm-duration/

    Package Sidebar

    Install

    npm i @ozean/set-webm-duration

    Weekly Downloads

    3

    Version

    0.1.3

    License

    MIT

    Unpacked Size

    58.5 kB

    Total Files

    12

    Last publish

    Collaborators

    • ozean