Blog : How WDM Avi Video Capture On Visual Basic?

How WDM Avi Video Capture On Visual Basic?


how to make WDM (not VFW) avi video capture in Visual Basic? I know SDK source code only for C++ (amcap). Wrote someone code about this? i need urgent help. thanks

View Complete Forum Thread with Replies

--------------------------------------------------------------------------------
See Related Forum Messages: Follow the Links Below to View Complete Thread
--------------------------------------------------------------------------------

•Playing A Video In Visual Basic And Capturing How Much Time The Video Has Played
•Video In Visual Basic
•TV-Video Card And Visual Basic
•Video Encoding In Visual Basic
•Play Video -- Visual Basic 6
•Play Streaming Video In Visual Basic??
•Transfer Video File Using Visual Basic 6
•Visual Basic 6.0 Video Training Tutorials
•Video Interface In Visual Basic Form
•Screen Capture With Visual Basic?
•Needed Vb Code For Live Video Chat Without Using Video Capture Card
•Capture Picture Through Webcam In Visual Basic !!
•How To Capture Error Message From DOS Prompt With Visual Basic
•Capture Video Using My Capture Card
•Video Capture
•Video Capture
•How To Use VMR With Video-capture?
•Video Capture
•Video Capture
•Video Capture
•Video Capture
•Video Capture
•Capture Video
•Capture Video
•Video Capture
•Video Capture
•Video Capture.
•Video Capture
•Streaming Video Capture
•Two Windows Video Capture
•How To End A Video Capture Process
•Mcisendstring Video Capture
•Screen Video Capture
•Capture 1st Frame Of Video
•Capture Video From IP Camera
•How To Control Video Capture ?
•Video Capture Card??
•DirectShow - Video Capture
•Video Capture For Cameras
•AtiWdm Video Capture
•Video Capture With Directshow Help
•Video Capture In Background
•How To Use Video Capture Card
•Webcam/video Capture
•Cctv Video Capture
•Video Image Capture!!!
•How To Close Video Capture .....
•Capture Image From Webcam Usb/s-video
•Video Capture Save Function
Playing A Video In Visual Basic And Capturing How Much Time The Video Has Played
Hi everyone,

I am a beginner in Visual basic.I want to play a video using visual basic and I want to capture the time the user has played that video.Please help me on the same.Thanks in advance
Vinod

--------------------------------------------------------------------------------

Video In Visual Basic
How do you play video's in visual basic? Does anyone know where I can get some sort of sample code? Thanks.

--------------------------------------------------------------------------------

TV-Video Card And Visual Basic
Hi All,
I would like to grab images with a Pinnacle PCTV video card.
I am looking for an appropriate activex control.
any help is appreciated.

Kind regards

--------------------------------------------------------------------------------

Video Encoding In Visual Basic
I recently had a request from a company that needs to pass some video from vcr to the computer but in means of using visual basic instead of the software it comes. They don't need an advanced encoding or stuff like that, they only need to pass video from vcr to the computer in which it is saved on a given directory and at the same time saving the path into the database, also to be able to play it in a form in visual basic and be able to capture any image from the video or even record a small segment of video into another video file. They want to skip the step of encoding the video through another program and then use visual basic to browse where is the file in order to save the path of it, so by having all these options on forms in visual basic is the most preferable way. Does anybody know any ocx or component that let me handle all this in VB???? I'll appreciate any suggestion / help.

--------------------------------------------------------------------------------

Play Video -- Visual Basic 6
To anyone who can help me, i am in desperate need of assistance. I am working on a project that involves playing video files. At the present time I am using windows media player but am not tied to it, and can use any tool to play the video clips.

The question I have is: How can i preload clips so that I can have them play one after the next with no delays or pauses. I tried to have two windows media player compenents so that when one was near completed the other one would load the next clip, but i wasnt able to make one visible and one visible after the first two, it always kept the second one on top.

Please, if oyu have any suggestions or experience with this, please, i beg of you to offer your guidenance as I am growing desperate.

thank you in advance,

Dave

--------------------------------------------------------------------------------

Play Streaming Video In Visual Basic??
Does anyone know how to play a streaming video in Visual Basic. For example i have an ASX file i need to play in my program that i need to play from this site:
http://www.hollywood.com/asplocal/re...tentid=1613716

Anyhelp would be greatly appreciated

Thanks,
Justin

--------------------------------------------------------------------------------

Transfer Video File Using Visual Basic 6
Ideas:

A person can watch a live video from the computer.

There are 2 computers that one of the computer is to transfer video files over network and the other computer is to receive it and play. I have a problem on how to transfer/receive live video files through internet using visual basic 6.....

Problems:

I don't know how to code the program and what controls should i use........
The internet protocol that i am using is HTTP and i'm using LAN network.

Is there anyone who can give me a hand on this?Any advice/guideline?
Thank you!

--------------------------------------------------------------------------------

Visual Basic 6.0 Video Training Tutorials
Does anyone know were i can Get some FREE Visual Basic 6.0 Video Training Tutorials.

its hard for me to read and understand
but a video i would be able to understand it well.

im kind of like if you gave me a book and it showed me how to disasemble a Airplane
i would read the book for a month and still not know a thing.

a Video is like watching some one do it
and if i had a Video of disasemble a Airplane
im the type of guy who could take it apart with Just a Butter Knife.

but all im looking for is,FREE Visual Basic 6.0 Video Training Tutorials.

--------------------------------------------------------------------------------

Video Interface In Visual Basic Form
I am developing a project, briefly discussing, this form is a visitor pass form. where in there is a requirement that when there is a visitor to the company, after they enter the details of the visitor they also need to put a photograph of that person. For which they are using a Web Camera, And an option with which they can take a print out of that pass with photo.

The question is how to use the driver of the Web Camera or give an interface in the VB Form such that by just click of a button on the form, his photo should appear in a place alloted on the form, and also should be able to take a print out.

-Prashanth

--------------------------------------------------------------------------------

Screen Capture With Visual Basic?
Any ideas about writing an Screen Capture with Visual Basic? any examples? Thanks

--------------------------------------------------------------------------------

Needed Vb Code For Live Video Chat Without Using Video Capture Card
hi guys,
  some one really help me out plz... i need a code in basic vb6 for live video chat using a web camera.the code should b able to live stream the image..basically a client and server is involved...the image should reach the server who should b able to retransmit it...AND ALLL THIS WITHOUT A VIDEO CAPTURE CARD(software based ha)....hope u got me rite...
  bye c ya ..plz reply as soon as possible



Edited by - vns on 2/14/2005 4:07:25 AM

--------------------------------------------------------------------------------

Capture Picture Through Webcam In Visual Basic !!
i have logitech webcam , i want to capture picture through webcam and automatically it will paste image on picturebox or imagebox in vb form.

--------------------------------------------------------------------------------

How To Capture Error Message From DOS Prompt With Visual Basic
Would like to know how to capture an error message from a DOS Prompt with Visual Basic 6. Any ideals would be great.

--------------------------------------------------------------------------------

Capture Video Using My Capture Card
how do i capture video using my video capture card? Can anybody help?

--------------------------------------------------------------------------------

Video Capture
Hi all,

Does anyone know how to create a second capture window? I have a capture window that receives images from my webcam, but I would like to create a second window that receives the same images (twin windows). The reason that I want to do that is that I want to build a client-server application using webcams.

Thank you

John

--------------------------------------------------------------------------------

Video Capture
Can anyone suggest to me the best way to do a simple video capture into an MPEG file.
I want to capture either from a video camera plugged into the fire-wire
OR
from what is displayed in a Windows Media Player Control

Any assistance or advise greatly appreciated

--------------------------------------------------------------------------------

How To Use VMR With Video-capture?
Hello

I have created the filter for my capture device, pCap.
When I use pGraph->Render(0,0,pCap,NULL,NULL) it works, and I get new window for the video capture.

I tried to create VideoMixingRenderer object, and add it to the graph. When I do pGraph->Render(0,0,pCap,NULL,pVmr), it seems that he connects the CAPTURE pin to the pVmr. How can I play it, like Preview?

thanks

--------------------------------------------------------------------------------

Video Capture
i am using the vid.ocx with my project to play the cable tv that i have comming into my ati wonder card. and i want to know is there a tool i can use to record what is playing and store it on my computer.

--------------------------------------------------------------------------------

Video Capture
Hi VB'ers!

What is the easiest way to get at video data (pixel values) from both (a) a webcam and (b) from a video capture card? Is it easy in VB? What API calls do I need? Does anone know of any good code examples / tutorials?

I've had a look at the Microsoft Vision SDK (in C++) which looks pretty good with it's interface to my webcam's settings. Is there anything similar in VB?

Any tips greatly appreciated!!

C_V :-)

--------------------------------------------------------------------------------

Video Capture
Hello, I know it is possible to get a capture device through API, although i am very stuck at the point i dont even know where to start apart from a nice interface .

Does anybody have any suggestions on what API i need to use to get the VideoCapture windows driver?

--------------------------------------------------------------------------------

Video Capture
Has anyone got an idea on how to get pictures from a video
in my vb program. I got a webcam... and want to do some
stuff with the pics.

Is there a standard way of interfacing (like vidcap does)...

--------------------------------------------------------------------------------

Video Capture
Hi,

Here is my project.
A stand-alone exe application.
User can select a video file from his own pc.
I would like to have a image of the video.
Like explorer when select view as "Thumbnails"

Any idea?? Possible ??

Thanks

--------------------------------------------------------------------------------

Capture Video
Is it possible to capture video from a frame? Like if there were a web browser frame and I wanted to capture all activity on it? I have code to capture an image from the frame in question, but I would like to also add the ability to capture video, preferably in a well compressed format, but otherwise it could be compressed later, any thoughts?

btw: If the video size must be fixed (like 320x240 or 640x480 etc) I could make the frame this size, but ideally, I would want to just select top and left on the screen (or all corners if necessary, similar to how I am capture the image).

--------------------------------------------------------------------------------

Capture Video
hi friends,

how to capture video of some particular size i mean the size shouldnt exceed 450 kb.

thanx

--------------------------------------------------------------------------------

Video Capture
Teacher

Pls. help me to capture image from a video signal ( RCA )

Thanks

--------------------------------------------------------------------------------

Video Capture
I have a video capture card in my computer and I wish to run a "getpixel" on it as opposed to the screen. Can I do it?

--------------------------------------------------------------------------------

Video Capture.
Hi there,

I want to capture stills from a video capture devide in my pc. HOW CAN I DO IT ?

The goal of this proj is to capture stills of videos for rent and put 1,2, 4, 6, 8 or 12 of them in a same page and print it as a catalogue.

Anybody ?

Thanks in advance.

--------------------------------------------------------------------------------

Video Capture
In my application i need to capture video through a capture card. I am using the avi capture apis to capture. the problem is that the captured file is in avi format taking up a lot of disk space. i want to capture the file in mpg format. i have seen other aplication doing that, like winVCR. can any body tell me how to acheive this. Thanks.

--------------------------------------------------------------------------------

Streaming Video Capture
I currently have a Windows Media Player control in my form that I am playing streaming video on. I would like to take screen captures of the video when I click a button. I have put the WMP in a Picturebox and when I save the image of the picturebox, it comes up blank. Can anyone tell me what I am doing wrong?

I really appreciate it!

--------------------------------------------------------------------------------

Two Windows Video Capture
i've found this window video capture program from planetsourcecode written by E. J. Bantz Jr.

anyone who is interested can have a look at the zipped file.
p/s: u need to install a webcam in order to see the result.

but i'm interested to enhance the program for supporting 2 webcams, means 2 window video capture.

what i need to do ??

should i duplicate the code one more time or create a ResizeCapture window ?

comments please~~

Greatly appreciate for any comments that help.

thanks

--------------------------------------------------------------------------------

How To End A Video Capture Process
currently i'm doing a survelliance system using webcam.

what is the code for aborting the video capturing process.

the property is in CAPDRIVERACAPS or CAPSTATUS or CAPTUREPARMS ??

i search it for a long time, but there's no fruitful result

please help~~

--------------------------------------------------------------------------------

Mcisendstring Video Capture
I am trying to figure out how to capture video using the mcisendstring.

Has any one know of any good examples

--------------------------------------------------------------------------------

Screen Video Capture
Is it possible to make a screen capture program using VB? if so can you link me some help?

--------------------------------------------------------------------------------

Capture 1st Frame Of Video
Hi,

Here is my project.
A stand-alone exe application.
User can select a video file from his own pc.
I would like to save a image for the video, but without playing the video
Like explorer when select view as "Thumbnails", a small image of 1st frame of video would be displayed.

Any idea?? Possible ??

Thanks

--------------------------------------------------------------------------------

Capture Video From IP Camera
Hi,

I have seven IP Camera linked on HUB/SWITCH.
There is also an PC Windows XP linked to the HUB/SWITCH.

How I can capture in simultaneously the video on MPG files?

Can I send over HTTP, with IIS on the Windows XP, custom pages with the video? For Example: 4 video/window, 6 video/window, 2 video/window, etc...

Need ActiveX?

I search for source code example, information on technology and any help.

Thanks

--------------------------------------------------------------------------------

How To Control Video Capture ?
Hi all,
I write a small program to capture video signal from video capture card. But I have 2 problems:
1. How to setup parameters of video capture card (exp: Video source, NTSC or Pal, .... etc ) without display the video format dialog box ?
2. How to change colors, brightness, contrast, ... when display video stream ?

Please help me as soon as.
Thanks so much.

--------------------------------------------------------------------------------

Video Capture Card??
Hi
Has anyone here ever written software for a "Video Capture" Card??
Any sample code??

--------------------------------------------------------------------------------

DirectShow - Video Capture
Does anyone has a link to a good site where I can get some infos about directshow with vb ??
I've found some infos, but I'm interested about video capture...
All the samples and infos were in C++....
I just want to know if I can do somthing in vb before going with a C++ program...

thanks!

--------------------------------------------------------------------------------

Video Capture For Cameras
I am looking for a video capture ActiveX for cameras but one that will let me get the stdPicture object of a current frame to memory. I need to grab the current frame as a jpg file and copy it to memory to stream without writing to the hard drive at all.

I've looked at a few out there but most of them only let me save the frame to the hard drive or to the clipboard. I am wanting to almost stream the frames but when I save it to the hard drive and then read it back in memory, that slows it down some.

Any help would be appreciated!

Warren

--------------------------------------------------------------------------------

AtiWdm Video Capture
Does anyone know how to use the (ati)wdm video capture in visual basic? Or does anyone know where to find documentation on it?

--------------------------------------------------------------------------------

Video Capture With Directshow Help
Hi

I have been struggling for some time with this issue if anybody would be able to give me some assistance it would be greatly appreciated.

I am trying to write this piece of VB.NET code with the directshow.net library. But I need to be able to save the file format to ensure that it is always YUYV.

But it just doesn't seem to want to work I am using the samplegrabber object to create this but it just breaks everytime it runs!

Any suggestions or help would be greatly appreciated.

The code below will only work if I set the media sub type to an RGB format.

the code I have is as follows:


Code:

Public Sub confSampleGrabber(ByVal sampleGrabber As ISampleGrabber)
Dim media As AMMediaType = New AMMediaType()
Dim hr As Integer

media.majorType = MediaType.Video
media.subType = MediaSubType.YUYV


media.formatType = FormatType.VideoInfo

hr = sampleGrabber.SetMediaType(media)
DsError.ThrowExceptionForHR(hr)

DsUtils.FreeAMMediaType(media)
media = Nothing

' Configure the samplegrabber callback
hr = sampleGrabber.SetCallback(Nothing, 1)
DsError.ThrowExceptionForHR(hr)
End Sub



Code:



Private Function fileCapture() As Integer
Dim captObj As New CaptureCardConf(theProperties)
Dim device As DsDevice
Dim sampleGrabber As ISampleGrabber
Dim capFilter As DirectShowLib.IBaseFilter = Nothing
Dim fileWriterFilter As IFileSinkFilter = Nothing
Dim baseGrabFlt As DirectShowLib.IBaseFilter = Nothing
Dim cConf As New CaptureCardConf(theProperties)
Dim hr As Integer
Dim muxFilter As DirectShowLib.IBaseFilter = Nothing


lblCapStatus.Text = "Setting Device"
lblCapStatus.ForeColor = Color.Orange
lblPrvState.Text = "Setting Up Live Feed"
lblCapStatus.ForeColor = Color.Red

If Not captObj.deviceActive Then
Try
getCaptureInterfaces()
If cConf.deviceList Is Nothing Then
cConf.deviceList = cConf.getDevices()
End If
device = cConf.deviceList(deviceIndex)
' Start building the graph
sampleGrabber = DirectCast(New SampleGrabber(), ISampleGrabber)

hr = captureGraphBuilder.SetFiltergraph(DirectCast(graphBuilder, IGraphBuilder))
DsError.ThrowExceptionForHR(hr)

hr = graphBuilder.AddSourceFilterForMoniker(device.Mon, Nothing, device.Name, capFilter)
DsError.ThrowExceptionForHR(hr)

baseGrabFlt = DirectCast(sampleGrabber, DirectShowLib.IBaseFilter)
confSampleGrabber(sampleGrabber)

hr = graphBuilder.AddFilter(baseGrabFlt, "UYVY Setter")
DsError.ThrowExceptionForHR(hr)

If fileName = Nothing Then
fileName = setSave()
End If

Dim regex As Regex = Nothing

fileName = directory + "" + fileName
fileName = System.Text.RegularExpressions.Regex.Replace(fileName, "\", "\")

hr = captureGraphBuilder.SetOutputFileName(MediaSubType.Avi, fileName, muxFilter, fileWriterFilter)
DsError.ThrowExceptionForHR(hr)

'Redners Video graph for the, sets up to access preview pin stream
hr = captureGraphBuilder.RenderStream(PinCategory.Preview, MediaType.Video, capFilter, Nothing, Nothing)
DsError.ThrowExceptionForHR(hr)

hr = captureGraphBuilder.RenderStream(PinCategory.Capture, MediaType.Video, capFilter, baseGrabFlt, muxFilter)
DsError.ThrowExceptionForHR(hr)

'Cleans up object
Marshal.ReleaseComObject(capFilter)

'Defines window location
SetupCaptureVideoWindow()

rot = New DsROTEntry(Me.graphBuilder)
DsError.ThrowExceptionForHR(hr)

Catch ex As Exception
Return 0

End Try

Return 1
Else
Return 0
'Clear Devices And graphs
'call setDefaultCaptDevice to run this again to get setup new device
End If
End Function

--------------------------------------------------------------------------------

Video Capture In Background
Hi folks

I am using a free video control to capture video in my VB aplication and it works fine but i want to capture video when the application window is minimized .but when the window is minimized the video control stops refreshing or doesnt update the display so i cant capture video....

any ideas suggestions

i think that gotfocus or lost focus things wont work in this case ..

thanx in advance

--------------------------------------------------------------------------------

How To Use Video Capture Card
I am building a application , in which i need to stream video (not through internet), juat as a Surveillance application. So how can i add this component into my application?

--------------------------------------------------------------------------------

Webcam/video Capture
Hi, i am trying to setup a simple program that captures images from my webcam and then sends them to my server or sends via http. I am trying to get the the program written by E. J. Bantz Jr to do this. The source code is available free on planet-source-code but i just cannot seem to save the image to disk or memory and then make into a very small jpeg file? I have tried many ocx but they are slow and the jpeg is big? Can anyone help?


Regards

Jules

--------------------------------------------------------------------------------

Cctv Video Capture
hi all

i have one video capture card with 4's input camera

i try to preview my 4's camera with vb, but always make my computer restart

does anyone can help me

thank you

--------------------------------------------------------------------------------

Video Image Capture!!!
Hi,

I'm trying to develop a program that plays a video file.... i was able to do that with a MMControl1 outputting onto a picture box or playing on a windowsmediaplayer1
the problem that i'm having is .... i want to capture the image from the video and save it.. or even display it onto another picturebox...

...i just want to recap my question:

i need to capture a frame of a movie onto a picturebox or save it.

please help!

--------------------------------------------------------------------------------

How To Close Video Capture .....
hello

i have written this application to capture video and to save the picture into database.its working fine ... but when i try to close my application its NOT CLOSING PERFECTLY . some times it hangs.

here is my code ....

(note : here i might have missed some variables ... but the application is running ...)

' variables declared in a module

Public Const CAP_START = &H400
Public Const CAP_GET_CAPSTREAMPTR = CAP_START + 1
Public Const CAP_SET_CALLBACK_ERROR = CAP_START + 2
Public Const CAP_SET_CALLBACK_STATUS = CAP_START + 3
Public Const CAP_SET_CALLBACK_YIELD = CAP_START + 4
Public Const CAP_SET_CALLBACK_FRAME = CAP_START + 5
Public Const CAP_SET_CALLBACK_VIDEOSTREAM = CAP_START + 6
Public Const CAP_SET_CALLBACK_WAVESTREAM = CAP_START + 7
Public Const CAP_DRIVER_CONNECT = CAP_START + 10
Public Const CAP_DRIVER_DISCONNECT = CAP_START + 11
Public Const CAP_EDIT_COPY = CAP_START + 30

' to connect to the driver
Function capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean
  capDriverConnect = SendMessage(lwnd, CAP_DRIVER_CONNECT, i, 0)
End Function

' to disconnect from the driver
Function capDriverDisconnect(ByVal lwnd As Long) As Boolean
  capDriverDisconnect = SendMessage(lwnd, CAP_DRIVER_DISCONNECT, 0, 0)
End Function

' to stop the capture
Function capCaptureStop(ByVal lwnd As Long) As Boolean
  capCaptureStop = SendMessage(lwnd, CAP_STOP, 0, 0)
End Function

Function capDriverGetCaps(ByVal lwnd As Long, ByVal s As Long, ByVal wSize As Integer) As Boolean
  capDriverGetCaps = SendMessage(lwnd, CAP_DRIVER_GET_CAPS, wSize, s)
End Function

'to copy a snap shot to the clipboard
Function capEditCopy(ByVal lwnd As Long) As Boolean
' Clipboard.Clear
  capEditCopy = SendMessage(lwnd, CAP_EDIT_COPY, 0, 0)
End Function


' in the main form module
Private Sub Form_Load()
  Dim lpszName As String * 100
  Dim lpszVer As String * 100
  Dim Caps As CAPDRIVERCAPS  ' CAPDRIVERCAPS declared in a

module
   
  ' Capture Window creation
  ' driver info
  capGetDriverDescriptionA 0, lpszName, 100, lpszVer, 100

  mywdc = capCreateCaptureWindowA(lpszName, WS_CAPTION Or WS_THICKFRAME

Or WS_VISIBLE Or WS_CHILD, 0, 0, 160, 120, Me.hwnd, 0)
   
  ' Setting the title of window
  SetWindowText mywdc, lpszName
   
  ' Setting the video callback function
  capSetCallbackOnStatus mywdc, AddressOf MyStatusCallback
  capSetCallbackOnError mywdc, AddressOf MyErrorCallback
   
  ' Connect to the driver
  If capDriverConnect(mywdc, 0) Then
  ' getting the capture driver capabilities
  capDriverGetCaps mywdc, VarPtr(Caps), Len(Caps)
   
  ' Scale on
  capPreviewScale mywdc, True
   
  ' Setting the preview rate
  capPreviewRate mywdc, 66
  'capPreviewRate mywdc, 86
   
  ' Start previewing the image
  capPreview mywdc, True
   
  ' resizing the widow to the whole image
  ResizeCaptureWindow mywdc
  End If

End Sub

private sub EndAppln
' code to end the application - called in form's queryunlocad and when close menu is selected in main form
  ' the below given are functions declared a module and called from the main form
   
  capSetCallbackOnError = SendMessage(lwnd,CAP_SET_CALLBACK_ERROR, 0,lpProc)

  capSetCallbackOnStatus = SendMessage(lwnd,CAP_SET_CALLBACK_STATUS,0,lpProc)
   
  capSetCallbackOnYield = SendMessage(lwnd,CAP_SET_CALLBACK_YIELD, 0,lpProc)
   
  capSetCallbackOnFrame = SendMessage(lwnd,CAP_SET_CALLBACK_FRAME,0,lpProc)

  capSetCallbackOnVideoStream = SendMessage(lwnd,CAP_SET_CALLBACK_VIDEOSTREAM, 0,lpProc)
   
  capSetCallbackOnWaveStream = SendMessage(lwnd,CAP_SET_CALLBACK_WAVESTREAM, 0,lpProc)

  capSetCallbackOnCapControl = SendMessage(lwnd,CAP_SET_CALLBACK_CAPCONTROL, 0,lpProc)

  capCaptureStop (mywdc)   
  capDriverDisconnect (mywdc)
  DestroyWindow (mywdc)  ' here the API declared in the module, called   

  UnLoad Me
  End   

End Sub

any one please suggest any changes to be made to my application TO SAFELY CLOSE MY APPLICATION

AND PLESE SUGGEST HOW TO OPTIMIZE MY APPLICATION (AS IT TAKES MUCH MEMORY AND PROCESOR TIME) TO MAKE SURE THE APPLICATION RUN SMOOTHLY ...

Thanks in advance

Mohan G


 

--------------------------------------------------------------------------------

Capture Image From Webcam Usb/s-video
hey guys,
I have been trying to make a simple webcam program, but untill now unsuccessfull.
All the samples i find are very old and wont work in visual basic2005

Like VideoOCX.

Who can provide me with a working example of a webcam picture capture?
it must be soo easy in vidual basic 2005

--------------------------------------------------------------------------------

Video Capture Save Function
I am using a program that someone created that allows me to view my webcam. It works great and ive modified it to what i need. But it did not come with a function that would allow me to save "Captures" to the local hard disk, or anywhere for that matter. My end all "want" is to send the file to an FTP server, where i can call it. But for now if i can get a simple function that saves it off to the hard drive, i'll fight with transferring the file to the FTP site later. The project i have been using has a module that holds a few Functions, i am assuming this is probably where i will put the function to save off the file. Here is the code for that file.


Code:
Option Strict Off
Option Explicit On
Module Module1

Public Const ws_child As Integer = &H40000000
Public Const ws_visible As Integer = &H10000000

Public Const WM_USER As Short = 1024
Public Const wm_cap_driver_connect As Integer = WM_USER + 10
Public Const wm_cap_set_preview As Integer = WM_USER + 50
Public Const WM_CAP_SET_PREVIEWRATE As Integer = WM_USER + 52
Public Const WM_CAP_DRIVER_DISCONNECT As Integer = WM_USER + 11
Public Const WM_CAP_DLG_VIDEOFORMAT As Integer = WM_USER + 41
Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hWnd As Integer, ByVal wMsg As Integer, ByVal wParam As Integer, ByVal lParam As Integer) As Integer
Declare Function capCreateCaptureWindow Lib "avicap32.dll" Alias "capCreateCaptureWindowA"(ByVal a As String, ByVal b As Integer, ByVal c As Short, ByVal d As Short, ByVal e As Short, ByVal f As Short, ByVal g As Integer, ByVal h As Short) As Integer
End Module
I went through the Windows SDK Multimedia stuff on MSDN, but the description for each Function is kind of vague. Can someone recommend a function and an example syntaxt that will help me with this problem.