I am using "Push Source Desktop" filter for capturing screen in my application.
I hide my application while recording is going on. Only a button for stopping the recording is visible on screen.
The button also gets recorded by the filter. During playback of the saved recording the button is visible along with rest of the screen region.
Is there any way I can prevent the button from getting recorded ?
My aim is to record the screen without the button. I cannot hide the button as it required for stopping the recording of my application.
I have tried to alter the alpha component of my button and make it semi-transparent. But still the filter captures the semi-transparent button.
How can I get the background region of the button and ignore the capturing of the button itself?
The problem has actually nothing to do with DirectShow. Long story short, DirectShow starts when you send the image you already have using DirectShow API and form factor of your software item.
Your question is how to display something on the desktop and grab from the same desktop excluding the part you present to user. I don't think you can implement it accurately without going in too many details, but quite so often you can do a trick like this: you know the position of your UI element so you can identify what's below it in terms of window Z-order (another application window or desktop etc). You can ask this window to repaint into your DC, and then combine the parts into the video you send downstream as a DirectShow source.
Related
So I have next problem:
I have two monitors and do video translation from web camera on one of them(secondary). I do it in full screen mode using
put_FullScreenMode().
It works fine but when I click any mouse button on area of primary monitor, window with video translation wrap into just window mode.
How can I save full screen mode working with primary monitor?
At the first, I move my video to the left (on secondary monito from primary) and use full screen mode.
if(monitors.GetCount() > 1)
gx.pVW->put_Left(primaryRect.right);
gx.pVW->put_FullScreenMode(OATRUE);
gx.pVW->put_Visible(OATRUE);
Thank you for your time.
[Much] older applications took advantage of FullScreenMode since API supplied a specific "full screen renderer" filter which efficiently took care of full screen presentation. Since then video adapters found their way into stretching of presented video and full screen mode become unnecessary. Windowed mode of video renderer (you are using) was also not a recommended mode compared to windowless any longer.
You would be better off using renderer in windowless mode right in your UI, in your window, form or dialog. Using borderless window hosting video renderer you can easily imitate full screen mode without actually change of display mode. Such window remains normal window and does not need to go back from full screen with another UI activity, e.g. such that happens on another monitor.
VMR filters themselves demonstrate the two ways of going fullscreen in their Filter Config property page:
Set Fullscreen does it the way you do and suffer from the mentioned issue. The other method does full screen mode using borderless window stretched to the extent of a monitor.
See also related discussion:
IVideoWindow::put_FullScreen returning only native video size
I'm really new to origami and quartz. I've only spent a few hours on it today and am still a little lost.
I'm trying to show some interaction for a website in a web browser. What patch would I use to register a mouse hover on a button or window? More specifically I've attached a link to show what kind of interaction i'm trying to achieve (Living Options section).
Also how do you use the mouse scroll patch?
Thanks
To register a mouse hover, you would use the setup pictured above. First you need to define a Hit Area (the area to be hovered). Plugged into this you need an Interaction patch. Finally, you need to define which kind of mouse interaction you want to track – in this case Mouse Over. You have have a number of options here:
Plug the Mouse Over output port into another patch, e.g. the Text patch.
Create a Wireless Broadcaster (pictured) to send the interaction anywhere else in your composition (via a Wireless Receiver).
Publish the output up one layer. To do this, hover over the desired port and hit 'p'. The output will now be available from the parent patch.
I saw another question that sounds almost the same but the answers seem to be about whole desktop screen capture: DirectShow Source filter using Dekstop window as source.
I have looked at the PushSource and yes it does what it is meant to do, however I want the virtual webcam to grab a specific window (similar to how you can select to share a window in Skype's share screen).
How would I go about selecting a specific window as a capture for the virtual webcam? is there a specific method already in the DirectShow API that I don't know about that does this?
There is no specific method. Moreover the part of the sample that grabs from screen is already outside of DirectShow API, it is GDI instead.
So the solution is pretty simple, you GetWindowRect position of your window, and then grab from screen only this rectangle, not the whole desktop. Or instead, you can send WM_PAINT or WM_PRINTCLIENT to the window in order to request its paint into provided device context.
I wish to understand how one can programmatically identify if a window is playing video content?
I used spy++ to identify particular attributes for windows playing video but I did not find any particular attributes associated with window playing video.
I have handles to all windows on screen and want to find which ones are playing video ? Could you please throw some light on how can one do this and are there any special properties associated with a window playing video?
I found similar article :
can we get window handle of the window which is playing video?
But I don't want to minimize application , I know user is using browser(ie,firefix,chrome) to watch video (from youtube,hulu)and window is visible on screen.
You can if you have execution privileges over the environment the Flash Player is executed in. You can listen for the playing event thrown by the Flash Player.
Listen for my Flash event in Javascript
Im writing an application for workers in our factory and one of requirements is that they should be able to take images using camera integrated in PDA with WM6.5.
The main difficulty is, that thay MUST NEVER EVER be able to enter windows, Start button, desktop etc. They are allowed ONLY to see my fullscreen application.
I succesfully deactivated BlueTooth + red, green and volume buttons (if you are interested, im pasting links here)
http://forum.xda-developers.com/showthread.php?t=546737
http://msdn.microsoft.com/en-us/library/bb431750.aspx
http://social.msdn.microsoft.com/forums/en-US/vssmartdevicesvbcs/thread/a4f9f41d-47a8-4080-8613-2c2ddcf4c012/
And now I have to implement the camera function. But as CameraCaptureDialog opens a new dialog and shows start button, task bar and allows user to open list of applications, I must not use it.
I must create my own dialog that will show the Live Preview in a panel or in an imageBox and photo will be taken using a button.
I searched the whole internet and found only DirectShow.NETCF (but people do not recommend it) and CameraCaptureDialog.
Can I somehow redirect the CameraCaptureDialog to my dialog? Or can I access camera directly via .NET framework? Or can I modify the CameraCaptureDialog not to show Start button, menu etc?
Looks like you have a bit of a challenge. I agree that Directshow is a questionable solution, but it may be your only option. I did get http://alexmogurenko.com/blog/directshownetcf/ to work, but only on low resolutions.
A better option might be to find a device that does not show the menu bar/start button. AFAIK, the HTC HD2 has a very clean Cameracapturedialog..
Good luck.