Search code examples
c++ffmpegdirectshowaero

FFmpeg disables Window Desktop Manager in my app


I render video using DirectShow & FFmpeg in my app. FFmpeg is only used for decoding of MPEG4/Part2 frames (custom decoder filter). My app does not play audio (only video).

When I lock my PC (Win7 Pro 64bit) with Win+L and then unlock it Windows brings me the following message:

The color scheme has been changed

The following program has performed an action that requires Windows to temporarily change the color scheme to Windows 7 Basic.

...app name, publisher, pid...

Windows will automatically change the color scheme back to Windows Aero when this program or other programs performing similar actions are no longer running.

I have a possibility of using another custom decoder filter which was developed without FFmpeg, and using it Windows does not show such messages to me.

I ran Aero troubleshooter that detected Desktop Window Manager was disabled.

My main question: Why this message appears after unlocking?

P.S. I'm using ffmpeg mpeg4 decoder, sws_scale from RGB24 to YUV420p. FFmpeg was built only with mpeg4 decoder/encoder, everything else was disabled.


Solution

  • The issue was caused by providing negative height (top-down bitmap) in bitmapinfoheader when negotiating media types. I changed height to be positive (bottom-up bitmap) in my decoder and color scheme of Windows 7 is not touched anymore.