
AuraJS native hosts can load and play codec-backed .mp4 files through the
existing aura.video surface.
This contract is intentionally narrow:
play / pause / stop / seek / getTexture / getInfo flowcreateVideoBillboardSurface(...) and
createMediaPresentationController(...)This contract does not claim:
.mp4 parity.mp4MP4 decode is handled in-process via the embedded video codec library. No external tools are required for video playback.
The in-process decoder supports the following video codecs inside .mp4
containers:
Container format is MP4 (ISOBMFF), auto-detected by file extension.
When an audio track is present in the MP4 container, it is automatically decoded and played back through the engine's miniaudio mixer. Supported audio codecs:
Audio is resampled to the engine format (44100 Hz, stereo, F32 interleaved) regardless of the source format.
Audio and video run free on the real-time clock. Both start on play() and
pause/stop together. On seek, audio is stopped and restarts on the next
play() call. This matches the existing media-presentation contract where JS
authors own fine-grained timing control.
Native .mp4 playback supports:
aura.video.load('assets/intro.mp4')type: 'mp4' or extension-driven auto-detectiondraw3d.billboard(...)getInfo(handle).sourceKind === 'mp4'source pathMinimal example:
const handle = aura.video.load('assets/intro.mp4', { type: 'mp4', looping: true });
const textureHandle = aura.video.getTexture(handle);
aura.video.play(handle);
For native builds and npm-first package/install flows:
.mp4 assets are preserved.mp4 as videodocs/native-media-presentation-contract-v1.mdCurrent native .mp4 support does not guarantee:
.webm, .mov, .mkv, or .avi