Quantcast
Channel: Media Foundation Development for Windows Desktop forum
Viewing all articles
Browse latest Browse all 1079

IMFSinkWriter::WriteSample drops frames / stutters when writing from D3D11

$
0
0

(Edited with simpler example)

I wrote a simple example which writes a Direct3D texture to a video using IMFSyncWriter. The texture changes each frame. The result should be a red vertical line moving 6 pixels to the right each 1080p frame. (I'm using a GeForce 980 Ti on Windows 10.)

Unfortunately, I have no idea how to get that working correctly. I put some results on YouTube:

What the result should look like. This happens if I used Sleep(10) after each frame.

What happens with no sleep.

What happens with Sleep(1).

What happens with Sleep(1) if MF_SINK_WRITER_DISABLE_THROTTLING is set to TRUE.

I can see no way to know from the sync writer that a frame has been written and I can change the texture. Surely there's some way to write without this conflict between updates and writes.



Viewing all articles
Browse latest Browse all 1079

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>