Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: BufferedImage -> QTHandle troubles



On Monday, January 14, 2002, at 02:50 PM, Ryan Francesconi wrote:


bi = new BufferedImage(_x, _y, BufferedImage.TYPE_BYTE_INDEXED);
_g = bi.createGraphics();


from BufferedImage javadoc:

TYPE_BYTE_INDEXED Represents an indexed byte image.


but unless you're planning on supplying a colour table, you probably really want something like:

TYPE_4BYTE_ABGR
Represents an image with 8-bit RGBA color components with the colors Blue, Green, and Red stored in 3 bytes and 1 byte of alpha.

or

TYPE_INT_RGB
Represents an image with 8-bit RGB color components packed into integer pixels.


these are all pixel formats that translate directly to pixel formats QuickTime understands, and are one pixel per int.


cheers,

dean


References: 
 >BufferedImage -> QTHandle troubles (From: "Ryan Francesconi" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.