get the picture from camera Desktop

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2729
Joined: Sat Dec 22, 2007 5:35 pm
Contact:

get the picture from camera Desktop

Post by jmburnod » Tue Nov 27, 2012 12:54 pm

Hi All,
I searched a way to get the picture of camera desktop and i didn't find anything in the forum
Is it possible or not ?
Best regards
Jean-Marc
https://alternatic.ch

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4163
Joined: Sun Jan 07, 2007 9:12 pm

Re: get the picture from camera Desktop

Post by bn » Tue Nov 27, 2012 2:21 pm

Hi Jean-Marc,

look in Help Menu -> Example Stacks and Resources -> Resources -> Sample Projects -> Video Capture.rev

/Applications/LiveCode 5.5.3.app/Contents/Tools/Resources/Sample Projects/Video Capture.rev

Kind regards
Bernd

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: get the picture from camera Desktop

Post by Klaus » Tue Nov 27, 2012 2:27 pm

Bonjour mes amies,

1. the example and the underlying technique is CRAP! 8)
Simply because this is only working (somehow) on the Mac, I NEVER got it to work on WIndows, neither with VfW nor with QuickTime!
Maybe the new video capture mechanism (OS X only! See the "Release Notes") is better (well, everything is better than this :D ), but I did not try it out.

2. I am afraid this will only work with VIDEO cameras (DV, Webcams etc.) and not with a photo camera.
I think this is what Jean-Marc is asking for.


Best

Klaus

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4163
Joined: Sun Jan 07, 2007 9:12 pm

Re: get the picture from camera Desktop

Post by bn » Tue Nov 27, 2012 2:42 pm

Hi Klaus,
the example and the underlying technique is CRAP!...
Simply because this is only working (somehow) on the Mac
I agree that there is ample room for improvement...

I thought Jean-Marc wanted to take a snapshot from the built-in camera on a Mac desktop computer. That does work from the preview of the example.

What does CRAP stand for? :)

Kind regards
Bernd

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2729
Joined: Sat Dec 22, 2007 5:35 pm
Contact:

Re: get the picture from camera Desktop

Post by jmburnod » Tue Nov 27, 2012 2:52 pm

Hi Friends,
Thanks one more for help
the example and the underlying technique is CRAP!
I think so
Image
Maybe the new video capture mechanism (OS X only! See the "Release Notes") is better (well, everything is better than this ), but I did not try it out.
Ok I'll study and test it and i'm coming back.

Would you have a look here ?:
http://forums.runrev.com/phpBB2/viewtop ... 400#p64603
I think the topic changed and that will be better to create a new topic "ProgressbarDuringDownloadDesktop". Right ?

Kind regards
Jean-Marc
https://alternatic.ch

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: get the picture from camera Desktop

Post by Klaus » Tue Nov 27, 2012 3:15 pm

Hi Bernd,
bn wrote:What does CRAP stand for? :)
See Jean-Marcs screenshot, which explains a LOT :D
I would translate it euphemistically with "Murks" into german 8)


Best

Klaus

bn
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 4163
Joined: Sun Jan 07, 2007 9:12 pm

Re: get the picture from camera Desktop

Post by bn » Tue Nov 27, 2012 3:32 pm

Hi Friends,

I think Jean-Marc's screenshot is the least of the problems.
The preview window is a "fake" window, it floats above everything. Just like RevBrowser.

But I do manage to get snapshots from the internal camera.

<joke>Although the snapshots do not clean up the room I am in. I would call that CRAP. I have to use Photoshop to take care of that mess. :) </joke>

Kind regards
Bernd

jmburnod
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2729
Joined: Sat Dec 22, 2007 5:35 pm
Contact:

Re: get the picture from camera Desktop

Post by jmburnod » Tue Nov 27, 2012 6:53 pm

Hi Friends,
I looked revCapture library. I didn't find anything about it in the dictionary but the release notes says:
Mac – revCapture video capture library (4.6.1 – experimental)
I'm giving up this way
I just need a snapshot and the videoCapture does this part of the job
Kind regards
https://alternatic.ch

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10078
Joined: Fri Feb 19, 2010 10:17 am

Re: get the picture from camera Desktop

Post by richmond62 » Sun Feb 22, 2015 10:33 am

So, here I am with Livecode 7.0.1 on Mac 10.8 and when I go here: Help Menu -> Example Stacks and Resources

I get directed to the RunRev website via Firefox . . . rubbish.

So I dug down inside the Livecode app package to find "Video Capture.rev" file and copied it to my desktop.

In the "video setting" section of the stack I can see my "lovely face" via my cheap-and-nasty webcam attached to
my Mac 10.8.

But the picture does NOT show up when I click the "Start Preview" button, BUT the "Grab Image" works . . .

So tried a button with this:

on mouseUp
revInitializeVideoGrabber the short name of this stack, "QT", "10,10,310,310"
revPreviewVideo
end mouseUp

as per the Documentation and got ABSOLUTELY NOTHING.

So tried: revSetVideoGrabberRect 10,310,10,600

and the IDE threw a bluey [ revSetVideoGrabberRect 10,310,10,600 }

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10078
Joined: Fri Feb 19, 2010 10:17 am

Re: get the picture from camera Desktop

Post by richmond62 » Sun Feb 22, 2015 10:45 am

Downloaded Devin Asay's "VideoGrabberTest.rev" ] http://livecode.byu.edu/video/videoGrabber.php ] and got very
smilar results to before: No preview.

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: get the picture from camera Desktop

Post by Klaus » Sun Feb 22, 2015 11:23 am

Hi Richmond,

LC now uses the AVFoundation for multimedia playback on the Mac now and NOT QuickTime anymore.

That means that -> "the dontuseqt" is set to TRUE per default in LC >=6.5x (?) and thus QT is not loaded
automatically anymore. Set it to FALSE in your pre-/openstack script and try again!

Or is it ONLY the preview that does not work and the rest does? :shock:


Best

Klaus

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10078
Joined: Fri Feb 19, 2010 10:17 am

Re: get the picture from camera Desktop

Post by richmond62 » Sun Feb 22, 2015 12:41 pm

Does that mean I should also expect that to work with Linux?

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: get the picture from camera Desktop

Post by Klaus » Sun Feb 22, 2015 5:14 pm

richmond62 wrote:Does that mean I should also expect that to work with Linux?
No.

Martin Koob
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 256
Joined: Sun May 27, 2007 8:19 pm

Re: get the picture from camera Desktop

Post by Martin Koob » Sun Feb 22, 2015 5:23 pm

Hi Richmond

As I understand it with more recent versions of Mac OS X QuickTime is deprecated. The player is now AVfoundation based. revVideoGrabber is QuickTime based but is now somehow wrapped to allow it to work with AVFoundation but the problem is that not all the revVideoGrabber features are working.

There is a bug where the preview does not show up with revVideoGrabber.

http://quality.runrev.com/show_bug.cgi?id=14339

Try switching to another application and then switch back to your stack running revVideoGrabber.

I found this workaround makes the preview appear but is not an actual fix.

Martin

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10078
Joined: Fri Feb 19, 2010 10:17 am

Re: get the picture from camera Desktop

Post by richmond62 » Sun Feb 22, 2015 7:08 pm

Um . . and the documentation is outdated . . . just for a change.

Post Reply