Skip to content

Zero duration for large WAV files (>7 hours (2,2 GB)) after save recording #553

@panchenkodv

Description

@panchenkodv

Package version 6.0.0

Environment

  • OS: Android
  • Browser [e.g. chrome, safari] if issue is on web platform.

Describe the bug

Broken headers on big wav files.

Add your record configuration RecordConfig(...)

const RecordConfig(
encoder: AudioEncoder.wav,
sampleRate: 44100,
numChannels: 1,
bitRate: 192000,
),

To Reproduce

Steps to reproduce the behavior:

  1. Start recording with config given above in a file
  2. Wait more than 7 hours
  3. Stop the recording and save it.
  4. File would have proper size, but in headers it would have 0 length. When you try to play it, you'll get 00:00:00 duration.

Expected behavior

File have proper duration.

Additional context

For files less than 2GB (<6,5 hours) everything is fine.
Also after using comand-line tool as sox like this
sox --ignore-length super_long_record_1760312595150.wav fixed_super_long_record_1760312595150.wav
fixed_super_long_record_1760312595150.wav is playable and contain all data which I record before.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions