Re: Take picture with iSight?
Re: Take picture with iSight?
- Subject: Re: Take picture with iSight?
- From: M Pulis <email@hidden>
- Date: Tue, 18 Nov 2008 06:39:21 -0700
I use the delegate:
-(CIImage *) view:(QTCaptureView *)view willDisplayImage : (CIImage *)
image
to grab a frame and bypass the basics. I found it straightforward to
transform and filter the frame as needed.
Found the technique in Apple sample code - forget which one now...
core image, core filters and nstransforms, qt .. all blurring a bit.
Gary
On Nov 18, 2008, at 6:14 AM, Graham Cox wrote:
On 18 Nov 2008, at 11:38 pm, Tim Andersson wrote:
Sorry, forgot to say that I have looked at the IKPictureTaker and
it isn't really what I'm looking for. I don't want the user to be
able to choose a picture or anything like that, I just want to
take a picture when the user clicks a button for example or when I
call a method in my code. Is this possible?
I don't need to support pre-Leopard.
A cursory scan of the docs suggests to me that a good place to
start looking would be QTCaptureDecompressedVideoOutput. This sends
a CVBufferRef to the delegate during capture, and there are methods
associated with that class to get basic information such as base
address, row bytes, height and so on, which would allow you to wrap
that buffer in a NSBitMapImageRep and from there to an NSImage and
so on....
So, that's probably what I'd be initially pursuing if it were me,
but take that with a pinch of salt as I might be way off.
hth,
Graham
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden