| Previous | Next |
| VFW_E_READ_ONLY | VFW_E_UNSUPPORTED_STREAM |
VFW_E_BUFFER_UNDERFLOW
Meaning
Windows documents VFW_E_BUFFER_UNDERFLOW as “The buffer is not full enough”. Here, a buffering component cannot satisfy an operation because too little data has accumulated.
Conditions that can produce it
- Cause 1: network input rate fell below consumption.
- Cause 2: playback began before the preroll threshold.
- Cause 3: incorrect bitrate or duration estimates set the threshold too high.
Relevant contract
This result occurs in the data-delivery and timing contract between DirectShow filters. Reference time, media time, sample flags, buffering and seeking formats are separate metadata channels and must not be substituted for one another without an explicit conversion.
Start with the first producer of the sample or seeking state and the immediate consumer.
Evidence worth preserving
- Evidence 1: buffer fill level and target threshold.
- Evidence 2: arrival and consumption rates over time.
- Evidence 3: source latency, read failures and playback rate.
Correction strategy
- Action 1: pause or delay consumption until sufficient preroll exists.
- Action 2: adapt thresholds to measured bitrate and latency.
- Action 3: distinguish temporary starvation from end-of-stream or permanent source failure.
Example incident
A network source starts immediately with only one packet buffered and starves on the first decode request; enforcing preroll prevents it.
Retry and recovery
Retry rule: Retry when additional data arrives or playback demand is reduced; use bounded backoff and cancellation rather than a tight loop.
How it differs from nearby results
VFW_E_TIMEOUT reports an elapsed deadline, whereas it reports an insufficient current data level that may recover as data arrives.
Official Microsoft references
Looking for a different code? Search another status or error code.