Click here to Skip to main content
15,899,124 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Working With USB to Parallel adapter Pin
Trollslayer23-Jul-06 9:45
mentorTrollslayer23-Jul-06 9:45 
GeneralRe: Working With USB to Parallel adapter Pin
McElwees24-Jul-06 15:05
McElwees24-Jul-06 15:05 
QuestionEscape characters Pin
jon-8023-Jul-06 7:53
professionaljon-8023-Jul-06 7:53 
AnswerRe: Escape characters Pin
Michael Dunn23-Jul-06 8:53
sitebuilderMichael Dunn23-Jul-06 8:53 
AnswerRe: Escape characters Pin
Steve Echols23-Jul-06 17:52
Steve Echols23-Jul-06 17:52 
QuestionVirtual WebCam Pin
DobosCake23-Jul-06 7:17
DobosCake23-Jul-06 7:17 
AnswerRe: Virtual WebCam Pin
Justin Tay23-Jul-06 7:44
Justin Tay23-Jul-06 7:44 
AnswerRe: Virtual WebCam Pin
DobosCake23-Jul-06 8:49
DobosCake23-Jul-06 8:49 
Thanks for your reply.

hfry wrote:
You lost me here. What do you mean by transmit it as if it comes from a webcam? It really just sounds like a file source filter to me...


If you use Skype, for example, when using video in Skype you can choose what device you want to get
your video from. My source filter appears as part of the capture devices in the list. The tweak here
that it's not connected to any hardware. Instead, A file dialog pops up when you choose it, and you're
supposed to choose a video file (i.e: AVI file). Then my source filter should simply is supposed to play the file and output the video AS IF it comes from a real WebCam.

Internally, I built a regular filter graph (using IGraphBuilder::RenderFile with the file you choose from the file dialog).

hfry wrote:

And what filters does this filter graph it consist of? Why would you build a complete playback graph only to remove the video renderer filter? If you would like to customize the graph you build without too much hassle use the ICaptureGraphBuilder2 interface.


hfry wrote:
Pass on what buffers? From where? To where? Are you taking the samples and BitBlt-ing yourself? The video renderers that come with windows don't wait for a WM_PAINT message to draw. If the renderer can't process samples fast enough it might start dropping samples.


The reason I'm removing the Video Renderer filter is because my filter shouldn't render the video. Just like a WebCam driver/filter doesn't have a renderer. It is added and connected externally (to the filter). I simply have to output what comes into the Video Renderer.

Atleast, that's the way I see it. I might be (completely) wrong.

When I used the Sample Grabber, it got the buffer that I want to pass on in another thread. For some reason which eludes me, the player (which is an external program) sometimes just didn't refresh the picture properly. Only once in a while. If I reran the file - sometimes it was just fine!

hfry wrote:
I've never seen filters disappear by themselves off GraphEdit, usually they just crash GraphEdit if they are buggy. I think you should debug your filter and step through the media type negotiation phase.


This is unrelated to the Sample Grabber issue, because I tried another approach. I decided to relinquish DirectShow's classes, and implemented most of the interface I needed myself. That's because I tried to just get the output pin of the filter that was connected to the Video Renderer (before I removed it) and delegate the calls from my output pin to that output pin, so that the
next filter (which is NOT in my internally built filter graph) would actually connect to that filter
and receive what the Video Renderer would have received.

I used GraphEdit. I added my source filter, and a Video Renderer. Then, when I connected them they suddenly disappeared. Since I was in debugging mode, I know they didn't crash. Actually they connected - but I assume that this problem is related to the fact that the pins are in different graph filter. My filter delegates the IPin calls to a pin which is in my internal filter graph, whereas the Video Renderer I added in GraphEdit is in GraphEdit's filter graph. I"m not sure though.

I know it sounds very complex.... that's why I'd appreciate any help.

Thanks.



GeneralRe: Virtual WebCam Pin
Justin Tay23-Jul-06 10:07
Justin Tay23-Jul-06 10:07 
AnswerRe: Virtual WebCam Pin
DobosCake23-Jul-06 23:48
DobosCake23-Jul-06 23:48 
Questionwhy use new() function in C++? Pin
kitty523-Jul-06 7:16
kitty523-Jul-06 7:16 
AnswerRe: why use new() function in C++? Pin
Chris Losinger23-Jul-06 10:03
professionalChris Losinger23-Jul-06 10:03 
GeneralRe: why use new() function in C++? Pin
kitty523-Jul-06 13:06
kitty523-Jul-06 13:06 
GeneralRe: why use new() function in C++? Pin
Chris Losinger23-Jul-06 14:11
professionalChris Losinger23-Jul-06 14:11 
QuestionArray of chars Pin
jon-8023-Jul-06 4:08
professionaljon-8023-Jul-06 4:08 
AnswerRe: Array of chars [modified] Pin
Justin Tay23-Jul-06 4:22
Justin Tay23-Jul-06 4:22 
QuestionNM_CUSTOMDRAW with the default ToolBar in MDI Pin
kdehairy23-Jul-06 1:39
kdehairy23-Jul-06 1:39 
AnswerRe: NM_CUSTOMDRAW with the default ToolBar in MDI Pin
Hamid_RT23-Jul-06 3:05
Hamid_RT23-Jul-06 3:05 
GeneralRe: NM_CUSTOMDRAW with the default ToolBar in MDI Pin
kdehairy27-Jul-06 7:42
kdehairy27-Jul-06 7:42 
GeneralRe: NM_CUSTOMDRAW with the default ToolBar in MDI Pin
Hamid_RT27-Jul-06 22:27
Hamid_RT27-Jul-06 22:27 
QuestionCListCtrl with static columns. Pin
paperke6723-Jul-06 1:35
paperke6723-Jul-06 1:35 
AnswerRe: CListCtrl with static columns. Pin
Hamid_RT27-Jul-06 7:25
Hamid_RT27-Jul-06 7:25 
GeneralRe: CListCtrl with static columns. Pin
paperke6729-Jul-06 2:29
paperke6729-Jul-06 2:29 
GeneralRe: CListCtrl with static columns. Pin
Hamid_RT29-Jul-06 2:55
Hamid_RT29-Jul-06 2:55 
QuestionListbox control variable ?? Pin
jon-8023-Jul-06 1:15
professionaljon-8023-Jul-06 1:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.