The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: Beshr on August 24, 2006, 12:25:17 PM

Title: WebCam
Post by: Beshr on August 24, 2006, 12:25:17 PM
Hi ALL

Is there is anyway to show my webcam in my MASM Application
If there is any way to do it without any DLL please tell it first!!

:dance: :dance: :dance: :dance: :dance:
Title: Re: WebCam
Post by: PBrennick on August 24, 2006, 12:48:32 PM
Beshr,
MASM can do anything you want, that is not the problem.  The problem is how.  You need to contact the maker of your WebCam to see if they have have a set of APIs that can be used to access the WebCam from your programming environment.  Do not tell them it is assembly, say C++, if they ask or you risk scaring them away.  As far as accessing the cam without using a DLL, my guess is you should forget that idea because the APIs would be useless to you as you would have to write the drivers yourself.  Stick with the APIs if they exist.  If they have nothing to offer, it will be a tough go for you.

Good luck, keep us posted,
Paul
Title: Re: WebCam
Post by: Tedd on August 24, 2006, 12:59:14 PM
Haven't looked into it, but I'd check to see whether DirectShow has anything to offer. I'm pretty sure there will be a 'standard' interface to access a webcam, it's just a matter of finding it :bdg
Title: Re: WebCam
Post by: Beshr on August 24, 2006, 03:11:47 PM
thx!
i want to use API because i heard that they'll be faster!!
dll are fast! but API is faster!!
is that right!?!
:dazzled: :dazzled:
Title: Re: WebCam
Post by: Tedd on August 24, 2006, 03:58:26 PM
In short, the API functions come from DLLs. So, no, not really.
(The only 'speedup' between using an api function and your own dll is that your dll will not have been loaded yet, but the dll containing the api functions may already have. But apart from this initial loading, there should not be any difference.)
Title: Re: WebCam
Post by: dsouza123 on August 24, 2006, 04:35:45 PM
An image viewing program I have used will connect to my webcam using twain32,
it will display video and capture snapshot images.

The program didn't come with the webcam, and worked with a previous webcam
I had from a different manufacturer.

Search for information on using twain_32.dll twain.dll or twain32 source code.
Title: Re: WebCam
Post by: P1 on August 24, 2006, 06:07:05 PM
Scronty has some source you can learn from:
http://www.scrontsoft.com/win32asm/webcamapp.zip

Make sure Phil gets some credit.

Regards,  P1  :8)
Title: Re: WebCam
Post by: Mark Jones on August 24, 2006, 06:20:39 PM
Also note that some webcams have a frame-rate limit, so even if you could access it faster, it might not make any difference. Realistically, any API you could use should be thousands of times faster than the camera, so I would not worry about making your own code. Use a .dll if it exists, it will save you a lot of time and energy. :U
Title: Re: WebCam
Post by: Vortex on August 24, 2006, 07:05:39 PM
QuoteThis application shows how to access webcam in Windows.
Written by Marcus Araujo.

http://flatassembler.net/examples/fasmcam.zip
Title: Re: WebCam
Post by: stanhebben on August 24, 2006, 07:42:08 PM
I found a lot of information at http://www.twain.org , but didn't use it myself. (not yet)
Title: Re: WebCam
Post by: Mark Jones on August 24, 2006, 09:15:09 PM
Interesting. I tried to port that code to MASM syntax, and found the API calls in VFW32.INC, but there is no VFW32.DLL on my system. There is however a MSVFW32.DLL. Investigating...
Title: Re: WebCam
Post by: P1 on August 24, 2006, 09:37:59 PM
Quote from: Mark Jones on August 24, 2006, 09:15:09 PMbut there is no VFW32.DLL on my system. There is however a MSVFW32.DLL.
We have gone over this before.  We need to update MASM with the new msvfw32 files.

Regards,  P1  :8)
Title: Re: WebCam
Post by: Mark Jones on August 24, 2006, 11:23:08 PM
MSVFW32.DLL doesn't seem to have all the same APIs in it that AVICAP32.DLL does. So I made import libraries for AVICAP32.DLL and a sample project. I cannot test it as I don't have a webcam. I do know however, that the save-bitmap function is not working. I have to go, perhaps someone else can finish this.

[attachment deleted by admin]
Title: Re: WebCam
Post by: Siekmanski on August 25, 2006, 01:35:34 PM
Hello

This is an example that uses vfw32.lib and saves a bitmap
I did test your avicap32.lib, it works OK.
( my proggy uses "capGetDriverDescription" which is not in your lib )

Regards, Siekmanski

[attachment deleted by admin]
Title: Re: WebCam
Post by: dedndave on May 05, 2012, 01:39:53 PM
i have seen a number of these, lately:
Quote[attachment deleted by admin]

is there like a secret password or something to access them ?
Title: Re: WebCam
Post by: Force on May 05, 2012, 02:42:57 PM
nice examples
Title: Re: WebCam
Post by: dedndave on May 05, 2012, 03:47:39 PM
yah - they totally wiped out this thread...
http://www.masm32.com/board/index.php?topic=937.0
which would have had some interesting code to learn from
Title: Re: WebCam
Post by: P1 on May 07, 2012, 11:57:16 PM
Quote from: dedndave on May 05, 2012, 01:39:53 PMi have seen a number of these, lately:
Quote[attachment deleted by admin]
is there like a secret password or something to access them ?
No.

hutch, had to make room by deleting attachments, for the growing database of messages, who is the leading reason for lots of messages, "Neener Neener Neener" ???

There is always cause to effect.

Regards,  P1  :8)
Title: Re: WebCam
Post by: dedndave on May 08, 2012, 02:11:39 AM
oh - i see
you're gonna blame me, huh
Title: Re: WebCam
Post by: P1 on May 08, 2012, 04:02:57 AM
Quote from: dedndave on May 08, 2012, 02:11:39 AMoh - i see
you're gonna blame me, huh
If you want to claim all the messages in the database, and have shoulders wide enough to carry the MASM32 website for responsibility, I will not stop you.

Between your perspective and attitude lies an answer.  Choose Wisely !!!

Regards,  P1   :8)
Title: Re: WebCam
Post by: dedndave on May 08, 2012, 04:06:03 AM
i dunno what rock you crawled out from under - lol
but, you can go back there, any time

the reason i have a lot of posts is because i try to help a lot of newbies
quite often, i have seen a question asked - and it sits there unanswered
i dunno - maybe that's not what they want the forum to be

i guess Hutch has to decide what he wants it to be, and make decisions, accordingly

but - you can jump in there, any time and try to help
then you can have a few more than 1200 posts, too
Title: Re: WebCam
Post by: P1 on May 08, 2012, 04:24:51 AM
Quote from: dedndave on May 08, 2012, 04:06:03 AMi dunno what rock you crawled out from under - lol
but, you can go back there, any time
I am a very primitive programmer, back to when evolution was 4bits, I love clubbing bits, bytes and code timing.
Quote from: dedndave on May 08, 2012, 04:06:03 AMthe reason i have a lot of posts is because i try to help a lot of newbies
quite often, i have seen a question asked - and it sits there unanswered
i dunno - maybe that's not what they want the forum to be
NOT THIS ONE, said they were un-neccessary, unless you feel guilty and wish to confess.   :naughty:
Quote from: dedndave on May 08, 2012, 04:06:03 AMi guess Hutch has to decide what he wants it to be, and make decisions, accordingly
The all powerful OZ has issued his commands to the ends of the earth(via internet) for all who seek wisdom and knowledge here.
Quote from: dedndave on May 08, 2012, 04:06:03 AMbut - you can jump in there, any time and try to help
I do what I do.  Oh, Moses programmer.  You may need to wonder 40 more years in the wilderness.
Quote from: dedndave on May 08, 2012, 04:06:03 AMthen you can have a few more than 1200 posts, too
From Everlasting to Everlasting, I am programmer god to a cpu somewhere.

Regards,  P1  :8)
Title: Re: WebCam
Post by: dedndave on May 08, 2012, 04:31:33 AM
Quote from: P1 on May 08, 2012, 04:24:51 AM
Quote from: dedndave on May 08, 2012, 04:06:03 AMi dunno what rock you crawled out from under - lol
but, you can go back there, any time
I am a very primitive programmer, back to when evolution was 4bits, I love clubbing bits, bytes and code timing.
Quote from: dedndave on May 08, 2012, 04:06:03 AMthe reason i have a lot of posts is because i try to help a lot of newbies
quite often, i have seen a question asked - and it sits there unanswered
i dunno - maybe that's not what they want the forum to be
NOT THIS ONE, said they were un-neccessary, unless you feel guilty and wish to confess.   :naughty:
Quote from: dedndave on May 08, 2012, 04:06:03 AMi guess Hutch has to decide what he wants it to be, and make decisions, accordingly
The all powerful OZ has issued his commands to the ends of the earth(via internet) for all who seek wisdom and knowledge here.
Quote from: dedndave on May 08, 2012, 04:06:03 AMbut - you can jump in there, any time and try to help
I do what I do.  Oh, Moses programmer.  You may need to wonder 40 more years in the wilderness.
Quote from: dedndave on May 08, 2012, 04:06:03 AMthen you can have a few more than 1200 posts, too
From Everlasting to Everlasting, I am programmer god to a cpu somewhere.

Regards,  P1  :8)

well - that was a real useful post   ::)
what the hell you smokin, boy ?
Title: Re: WebCam
Post by: P1 on May 08, 2012, 05:52:04 AM
Quote from: dedndave on May 08, 2012, 04:31:33 AMwell - that was a real useful post   ::)
what the hell you smokin, boy ?
Your omniscience of life is not high enough, to reach this far yet.
Quote from: dedndave on April 30, 2012, 04:47:52 AMdon't give me no shit about "quality of posts", etc, either - lol
Take your own "advise" brand.  Care to try some ???

If it gets any deeper, we may need to split(anagram coming soon) the thread, spit(oral refuse) goes one way and the slit(camera openning) goes another.

Regards,  P1  :8)
Title: Re: WebCam
Post by: vanjast on May 08, 2012, 10:16:49 PM
P1 and DenDave.. you're from the same 4bit era as many of us... cool down dudes - we all have our moments  :wink

I think I have some nice webcam stuff saved, and half dev'd a cam proj myself.. somewhere..maybe I can upload it...
If I can find it...'old-timers' kicking in
:bg
Title: Re: WebCam
Post by: dedndave on May 09, 2012, 01:07:47 AM
it's the GDI+ stuff i was interested in - and image conversion/loading
no worries - i will do it on my own
Title: Re: WebCam
Post by: mineiro on May 09, 2012, 03:50:57 AM
I do not know if I'm doing the right thing in re-posting that file here. If not, please, say and I will follow your comments.
Title: Re: WebCam
Post by: dedndave on May 09, 2012, 04:13:28 AM
thanks   :U
Title: Re: WebCam
Post by: Force on May 09, 2012, 12:46:16 PM
Yeah Calm down @ P1 and Dave   :dazzled:
If there is a problem.... Fighting is not a solition  Sure We can solve it without fighting also

there are still attachments  around here  :toothy

http://www.masm32.com/board/index.php?PHPSESSID=146eb9ac9e410f7657d87125b446a93c&topic=14750.0  (http://www.masm32.com/board/index.php?PHPSESSID=146eb9ac9e410f7657d87125b446a93c&topic=14750.0)