directshow

Directshow filter access threading

匿名 (未验证) 提交于 2019-12-03 01:31:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I made a TV-Player in c# using directshowlib-2005. now I made a method to search for available channels. I want this method to run in a different thread so my GUI won't freeze, but I get an error when I try to set the channel in the method. It can't find the IAMTVTuner interface in my graph, altough I know it's there. If I don't use a different thread, the method works just fine (but my GUI freezes for a while) I know it has to do something with apartments, but is there a way I can acces that interface in a different thread then

DirectShow code crashes after exit (PushSourceDesktop sample)

匿名 (未验证) 提交于 2019-12-03 00:48:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm trying to use the Desktop capture filter that comes with the SDK (PushSourceDesktop). I compiled it and seem to use it successfully as it actually captures my desktop and saves it to a file. But the application crashes when its done/exits. When I break on the error it only says no source available and the call stack location is KernelBase.dll!7560280C(). I thought I give it a shot here to see if anyone can recognize some issue or if I am doing something blatantly wrong that might cause the crash. Thanks in advance! EDIT: working code int

FFmpeg Hardware Acceleration -> GPU + DirectShow

寵の児 提交于 2019-12-02 23:43:06
Is there a hardware accelerated version of FFmpeg (e.g. a version that utilizes the GPU)? Also, does anybody use FFmpeg with GPU support? Possibly for scaling and converting video format? Or, for example, use DirectShow for image scaling and displaying images on surfaces? If so anybody can provide small code samples? There are some VDPAU accelerated codecs for unixes with nVidia card. There is also an mpegvideo_xvmc codec using XvMC that can decode MPEG-1 and 2 on X11 if the driver has support for it, and also some codecs using VA API . For Windows, ffmpeg supports DXVA 2. If you want to use

Crossbar filter change current input to Composite

拟墨画扇 提交于 2019-12-02 19:52:29
问题 I am new to DirectShow. I am writing an application in C# for capturing from Analog capture card. I have an analog capture card & I want to know how to change Analog Crossbar filter property, from "0: Analog Tuner In" to "1: Video Composite In". Here is my Filter Graph I can not connect Tuner's "Analog Video pin" to "Video Composite In" of Crossbar filter. I tried running "Route" method of IAMCrossbar filter, which failed. I don't know whether my path is correct. Please guide... 回答1:

DirectShow Virtual Camera does not appear in the list on some configurations

守給你的承諾、 提交于 2019-12-02 14:53:00
问题 I'm using DirectShow filter as virtual camera (CLSID_VideoInputDeviceCategory). It's working good but some apps/configurations do not display this feed as source. For example on win 8.1 I can see this source in Chrome/Firefox via webrtc. But in win 10 - chrome does not show this source in the list (but FF does). Also adobe flash does not show it in the list everywhere. What is important for me now is to make it available on win 10 /chrome. What may affect on this and how to fix it? Update

When changing a file name, Recording Start is overdue for 3 seconds.

纵饮孤独 提交于 2019-12-02 12:48:39
Using Two ASFWriter Filters in a graph.One is making wmv file, Anather is for live streaming. Carrying out streaming, When changing a file name, Recording Start is overdue for 3 seconds. so,The head of a New WMV is missing. It's troubled. CAMERA ------ InfTee Filter --- --- AsfWriter Filter → WMV FIle X Microphone --- InfTee Filter2 --- --- AsfWriter Filter2 → Live Streaming void RecStart() { ... ConnectFilters(pInfTee,"Infinite Pin Tee Filter(1)",L"Output1",pASFWriter,"ASFWriter",L"Video Input 01")); ConnectFilters(pInfTee,"Infinite Pin Tee Filter(2)",L"Output2",pASFWriter2,"ASFWriter",L

Text overlay when video is recording using Directshow and C#

放肆的年华 提交于 2019-12-02 11:05:36
By using DirectShowLib i can able to record the video by using ASF writter here is the code to start recording try { IBaseFilter capFilter = null; IBaseFilter asfWriter = null; IFileSinkFilter pTmpSink = null; ICaptureGraphBuilder2 captureGraph = null; GetVideoDevice(); if (availableVideoInputDevices.Count > 0) { // //init capture graph // graphBuilder = (IFilterGraph2)new FilterGraph(); captureGraph = (ICaptureGraphBuilder2)new CaptureGraphBuilder2(); // //sets filter object from graph // captureGraph.SetFiltergraph(graphBuilder); // //which device will use graph setting // graphBuilder

DirectShow capturing to multiple files

不羁岁月 提交于 2019-12-02 10:12:13
I have a problem: I need to capture live source to file, but with every-minute slice (without loosing any frames). I think, I need some filter that can receive raw video at input pin, output the same, but it should be able to stop transfering through itself (with saving incoming samples in some buffer). So I can stop and delete filters after that filter (encoder and file-writer) with IFilterChain without stopping the entire graph, create it again and continue capturing. Well, my question is: is thare such filter? Or is there any another solution for my problem? Please, don't offer to stop the

How to write an own capture filter?

时光毁灭记忆、已成空白 提交于 2019-12-02 09:45:57
Here's a great article on capturing video: http://nerdlogger.com/2011/11/03/stream-your-windows-desktop-using-ffmpeg/ it uses UScreenCapture filter. This time I need to use a custom filter, how to write one? And how to register so that FFmpeg can see that? Roman R. ffmpeg uses DirectShow video capture devices available in the opreating system, see more details on this forum thread: DirectShow Capture support . So you need to make a counterpart virtual source device to be picked up by ffmpeg . Your resources are: Multiple SO topics - Virtual webcam input as byte stream Windows SDK - PushSource

Custom virtual video capture device

吃可爱长大的小学妹 提交于 2019-12-02 09:23:38
I`m new to media foundation and C++. But I want to create a virtual video capture device which can be used by Microsoft Expression Encoder. Can you tell me in which direction to look? I think it should be something working asynchronously and a source will be byte stream from mobile device. Thanks in advance. Roman R. I don't think you want to look into Media Foundation for this. Expression Encoder uses a richer API to capture video with, DirectShow . You want a virtual DirectShow camera, which was discussed multiple times and has a simple sample project to start from. Virtual webcam input as