quicktime-api
[Prev] Thread [Next] | [Prev] Date [Next]
Re: Using VDSetCompression Milton Aupperle Fri Sep 07 06:07:19 2007
Hi Simon; On 6-Sep-07, at 10:41 AM, Simon Raisin wrote:
On 9/5/07, Milton Aupperle <[EMAIL PROTECTED]> wrote:This has nothing to do with what the VDIG delivers. In the Settings Panel that indicates what you want the Sequence Grabber to deliver when it's configured to record. So the SG will take whatever native format the VDIG delivers and then compress it (if possible) using your specified Compression Codec.Ok, I think I understand this now Milton - thank you.If you want to know what the VDIG can actually deliver try calling VDGetCompressionTypes() and looking at the VDCompressionListHandle that gets returned. The VDCompressionListHandle contains at least one VDCompressionList structure and may contain more.Ok, upon initialization I iterate through the VDCompressionList structs to determine what my VDIG is capable of delivering.Now that I know what is available, I'm still confused as to *where/ when* I need to perform my desired setup (no compression, 100% sharpness, 0% saturation, 15 fps, depth: 256 grays).
Don't forget that if you ask for 8 bit grayscale "none" or RAW Codec, your likely going to get something weird out especially if it uses the standard 8 bit Monochrome CLUT (Color Look Up Table) with a GWorld / PixMap / PixMapHandle.
When Apple developed the first Mac, they defined grayscale as being 0 for white and 255 for Black, and all the shades of gray in between them via a CLUT. So if I wanted Black, I used a value of 255 and in the CLUT look up table that generates an RGB of 0,0,0.
This is still true to day and if you use the Apple standard gray scale CLUT, then your values are reversed. Most savy developers now create a custom Clut that has 0 index mapped to RGB 0,0,0 black and 255 being white (255,255,255 or 65535, 65535, 65535 for old QuickDraw RGB colors structs used in a CLUT). This preserves the original intent of the camera data (0 = darkest, 255 = lightest) and matches the RGB display on screen.
Do I do this right when I initialize the SG or when I am creating the decompression session for the first time? (I think it is the latter, but I am not sure).
Anything that changes the video format, video depth or image size should be done before you set up the decompression session. Also If your going to manipulate the VDIG directly behind the SG's back, don't forget to call SGVideoDigitizerChanged() so that the SG can update it's status too after your done.
Thank you again for all your help - I'm waiting for you to write a book so I can stop bothering you directly. :)
Writing a book would be pointless because everything will be trashed / obsolete / re-done with Leopard (which is still secret and us long time VDIG writers have NEVER been consulted on this at all). Then it will only be another 5 years before we have stable video capture again with some meager documentation, but that's the Mac pessimist in me. I've only been writing Mac software now for 24 years now, so what would I know about "Look and Feel", "Quality and Assurance Testing" or "Developer Relations".
HTH.. Milton J. Aupperle President ASC - Aupperle Services and Contracting Mac Software (Drivers, Components and Application) Specialist #1005 - 815 14th Avenue. S.W. Calgary Alberta T2R0N5 1-(403)-229-9456 [EMAIL PROTECTED] www.outcastsoft.com Proud Supporter of the "Party of Alberta" http://www.partyofalberta.org/
_______________________________________________ Do not post admin requests to the list. They will be ignored. QuickTime-API mailing list ([EMAIL PROTECTED]) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/quicktime-api/alexiscircle%40gmail.com This email sent to [EMAIL PROTECTED]
- Using VDSetCompression Simon Raisin
- Re: Using VDSetCompression Simon Raisin
- Re: Using VDSetCompression Milton Aupperle
- Re: Using VDSetCompression Simon Raisin
- Re: Using VDSetCompression Milton Aupperle <=
- Re: Using VDSetCompression Mike Kluev