Stable documentation 0.1.x

The stable line provides basic single-video export, audio extraction, and waveform generation.

📦

Installation

npm install @projectyoked/expo-media-engine@0.1.3
npx expo prebuild

Requires a development build. Expo Go is not supported.

Requirements

RequirementMinimum
Expo SDK49+
expo-modules-core1.0.0+
iOS13.4+
Android API21+
React Native0.64+
🔍

isAvailable

Returns true if the native module is linked correctly.

import MediaEngine from '@projectyoked/expo-media-engine';
MediaEngine.isAvailable(); // boolean
🎵

extractAudio

Pulls the audio track from a video file and writes it to a .m4a file.

await MediaEngine.extractAudio(
  'file:///path/to/video.mp4',
  'file:///path/to/output.m4a'
);
〰️

getWaveform

Returns a normalized array of RMS amplitude values (0–1) for waveform visualization. The optional second argument controls the number of samples.

const amplitudes = await MediaEngine.getWaveform('file:///audio.mp3', 200);
// number[] of length 200
🎬

exportComposition

Single-video export with optional text/emoji overlays and background music.

Required fields: videoPath, outputPath.

Quality: set quality ('low' | 'medium' | 'high') or provide an explicit bitrate in bps.

Overlays: use parallel arrays — textArray, textX, textY, textColors, textSizes, textStarts, textDurations, and equivalent emoji* fields.

Audio mix: musicPath, musicVolume, originalVolume.

🟦

TypeScript

The stable line uses ExportCompositionConfig and related types. The full package definition file (including pre-release APIs) is below; it matches src/index.d.ts.

Loading types…