Questions tagged [ms-media-foundation]

Media Foundation is an API which enables development of multimedia applications on Windows.

Media Foundation is an API which enables development of multimedia applications on Windows. Media Foundation is intended to replace DirectShow.

Please refer Media Foundation documentation for more details.

846 questions
6
votes
1 answer

Raw Audio File to AAC using Windows Media Foundation on Windows 7

Thanks for taking some time to read my question. I'm developping a C++ application using Qt and windows API. I'm recording the microphone output in small 10s audio files in raw format, and I want to convert them to aac format. I have tried to read…
Eyal Hadida
  • 81
  • 1
  • 4
6
votes
1 answer

How do I use the Direct3D Device Manager?

I'd like to share one Direct3D device between multiple threads and objects in my Direct3D application. I came across the Direct3D device manager, which looks like what I want, although I'm not doing any video processing or video…
Christian
  • 61
  • 3
5
votes
0 answers

Windows Hello IR Camera - How to Modify the Current Mode of the InfraredTorchControl with C++/WinRT Media Foundation Platform APIs

Test Environment OS: Windows 11 Home 22H2 IR Camera: NexiGo HelloCam N930W Camera IDE: Visual Studio 2202 programming language: C++ 20 Application Kinds: Windows Desktop Application (C++/Winrt) [not universal Windows App][Xaml UI]. Source Code:…
5
votes
1 answer

MediaFoundation: Registering custom ClassFactory doesn't work

Background: I'm encoding NV12 buffers into h264 video stream wrapped in MPEG4 container using SinkWriter. Everything works fine but one problem though, as the SinkWriter abstracts the low-level encoder configurations I'm unable to control the…
iamrameshkumar
  • 1,328
  • 1
  • 14
  • 34
5
votes
0 answers

Microsoft Media Foundation / UVC ReadSample() callback

I'm writing a Media Foundation app to acquire and display 1920x1080 YUV2 images from a UVC camera at 60Hz. My problem is that the ReadSample() callback only gets called erratically at a very very low rate (1 FPS or so), in burst of a few…
JPh
  • 536
  • 3
  • 20
5
votes
1 answer

MediaFoundation, bitmap array to mp4

I hold bitmaps as BYTE arrays which holds RGB values of each pixel in a very similar and interchangeable format with microsoft's CBitmap class. So lets consider I have an array of CBitmaps and I want to convert them to mp4 with MediaFoundation…
top secret
  • 53
  • 4
5
votes
2 answers

Media Foundation EVR and DirectX 11

I am trying to write an EVR for Media Foundation using DirectX 11 on Windows 10 (Desktop). The only one solution I have found so far is here Unfortunately I don't know (as many others) how to correctly use it. Does somebody can point me to the right…
5
votes
1 answer

Using Media Foundation to encode Direct X surfaces

I'm trying to use the MediaFoundation API to encode a video but I'm having problems pushing the samples to the SinkWriter. I'm getting the frames to encode through the Desktop Duplication API. What I end up with is an ID3D11Texture2D with the…
5
votes
2 answers

NAudio - MediaFoundationReader: constructor doesn't take a delivered m4a-URL (from a youtube-Link)

I am trying to play an M4A (MP4 Audio) file directly from the internet using a URL. I'm using NAudio with the MediaFoundation to achieve this: using (var reader = new MediaFoundationReader(audioUrl)) //exception using (var wave = new…
PHilgarth
  • 285
  • 1
  • 3
  • 19
5
votes
1 answer

Why does MediaElement sometimes silently fail and how can I correct it?

In my WPF project I have created a view that includes several MediaElements playing videos. Sometimes, anywhere between one or all of the MediaElements will fail to play the video assigned to them, and will instead show a black rectangle, or not…
duggulous
  • 2,427
  • 3
  • 23
  • 40
5
votes
1 answer

can't add audio stream to MP4 file using sinkwriter from Media Foundation

It's been a week since I'm trying to make my encoder works... So the things is: I create a file using the Sink Writer from MF. I write all my video sample. --> (If I stop there and call the Finish methods, I'm able to read the file using VLC but if…
Nox
  • 932
  • 1
  • 9
  • 27
5
votes
1 answer

Color Converter DSP ProcessOutput always returns MF_E_TRANSFORM_NEED_MORE_INPUT

I need to convert video frames from RGB32 to IYUV but the Color Converter MFT refuses to process samples. For every frame I call IMFTransform::ProcessInput() and IMFTransform::ProcessOutput() but I receive MF_E_TRANSFORM_NEED_MORE_INPUT. If I try to…
Pawel
  • 51
  • 2
5
votes
2 answers

How to grab constant stream of bitmap images from webcam in c#

We have a c# application that performs processing on video streams. This is a low-level application that receives each frame in Bitmap format, so basically we need 25 images each second. This application is already working for some of our media…
Stanley
  • 5,261
  • 9
  • 38
  • 55
5
votes
2 answers

Microsoft Media Foundation Transform (MFT) with C#?

Does anyone know if Microsoft MFTs for Win7 can be written in C#? If so, is there any book or website that would help me in this.
phshah
  • 51
  • 1
  • 3
5
votes
2 answers

Whole screen capture and render in DirectX [PERFORMANCE]

I need some way to get screen data and pass them to DX9 surface/texture in my aplication and render it at at least 25fps at 1600*900 resolution, 30 would be better. I tried BitBliting but even after that I am at 20fps and after loading data into…
LeonidasCZ
  • 153
  • 1
  • 8
1 2
3
56 57