Solved

Video Capture

Posted on 1998-10-30
5
444 Views
Last Modified: 2013-11-20
Hi,

I want to write a little capture program for my video board
(Intel SmartVideo Pro).
Can anyone tell me what MCI commands do I have to send?
All I want to get is a single frame.

Thanks in advance,

Bernardo.
0
Comment
Question by:bsw
  • 3
  • 2
5 Comments
 

Accepted Solution

by:
zqian103198 earned 200 total points
ID: 1324060
Two easy ways to use standard Video Capture
MCI string :
pass the following strings to mciSendString      
"open overlay alias tester"  // open video overlay with // alias "tester"
"put tester client at 100 100 300 200"
"put tester destination at 0 0 300 200"
"put tester video at 100 100 300 200"
"window tester state show text my_tester_example" // show video //overlay window
"freeze tester" // stop for one frame
"close tester"
=======================================
or you can try vfw as
      hWndC = capCreateCaptureWindow (
      (LPSTR) "My Capture Window", // window name if pop-up
      WS_CHILD | WS_VISIBLE,       // window style
      0 , 0, 320, 240,              // window position and //dimensions
      m_hWnd,  
      0 );

      if ( ! capDriverConnect( hWndC , 0) )
      {
            MessageBox("Sorroy , not able connect video                 driver") ;
            return ;
      }
// .
// .
// .
      capGetStatus(hWndC, &CapStatus, sizeof (CAPSTATUS));
      ::SetWindowPos(hWndC, NULL, 0, 0, CapStatus.uiImageWidth,
            CapStatus.uiImageHeight, SWP_NOZORDER |         SWP_NOMOVE);

capDriverGetCaps(hWndC, &CapDrvCaps, sizeof (CAPDRIVERCAPS));
if (CapDrvCaps.fHasOverlay)
    capOverlay(hWndC, TRUE); // start video capture overlay
      
     capOverlay(hWndC, FALSE) ;  // stop at current frame
      
      capGrabFrame(hWndC) ; // grab one frame
// note :don't forget  vfw.h and vfw32.lib
0
 

Author Comment

by:bsw
ID: 1324061
Do you know how I can use these functions from delphi without having to write a DLL in C?
Thank you very much for your help!
:-D

0
 

Expert Comment

by:zqian103198
ID: 1324062
Hi, No need to write C DLL. Just call mciSendString or capCreateCaptureWindow etc. in your Delphi application. MCI and VFW are windows95's feature. You can find their support from Win32 SDK.
0
 

Author Comment

by:bsw
ID: 1324063
Thanks again!
:-D

0
 

Expert Comment

by:zqian103198
ID: 1324064
You're welcome!
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Smart Camera scanning and reading information 3 106
countEvens challenge 2 97
Change to event 1 111
Updating statistics with error notification email in SQL server 4 94
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

816 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now