|
JClass DesktopViews 6.3.0 API Documentation |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.klg.jclass.util.swing.encode.AbstractImageEncoder
This is the base class for encoding a component to a stream file.
Constructor Summary | |
AbstractImageEncoder()
|
Method Summary | |
static byte |
byteFromChar(char ochar)
|
static byte |
byteFromInt(int value)
|
static byte[] |
bytesFromInt(int value)
|
static byte[] |
bytesFromLong(long value)
|
byte |
compressColor(int clr)
Compress the given color into one 8 bit representation. |
byte |
compressColor(int red,
int green,
int blue)
Compress the given color into one 8 bit representation. |
static byte |
createByte(int b7,
int b6,
int b5,
int b4,
int b3,
int b2,
int b1,
int b0)
|
void |
encode(Component component,
OutputStream os)
Encode the specified component on the specified stream |
void |
encode(Image image,
OutputStream os)
|
protected void |
error(String msg)
|
abstract void |
saveImage(Image image,
OutputStream os)
|
static Image |
snapshot(Component component)
|
protected static void |
snapshotJava3d(Component component,
Graphics igc)
Run through the component and its children looking for those that implement Java3dImageable. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AbstractImageEncoder()
Method Detail |
public void encode(Image image, OutputStream os) throws IOException, EncoderException
encode
in interface Encoder
IOException
EncoderException
public void encode(Component component, OutputStream os) throws IOException, EncoderException
Encoder
encode
in interface Encoder
IOException
EncoderException
public static Image snapshot(Component component)
protected static void snapshotJava3d(Component component, Graphics igc)
component
- the component to test for Java3d Image drawing capabilityigc
- the Graphics object representing the parent image being drawn topublic abstract void saveImage(Image image, OutputStream os) throws IOException, EncoderException
IOException
EncoderException
public static byte createByte(int b7, int b6, int b5, int b4, int b3, int b2, int b1, int b0)
public static byte byteFromInt(int value)
public static byte[] bytesFromInt(int value)
public static byte[] bytesFromLong(long value)
public static byte byteFromChar(char ochar)
public byte compressColor(int clr)
clr
- integer representation of rgb value (lowest byte is blue,
second lowest byte is green, third lowest byte is red)
public byte compressColor(int red, int green, int blue)
red
- value of the red portion of the colorgreen
- value of the green portion of the colorblue
- value of the blue portion of the color
protected void error(String msg) throws EncoderException
EncoderException
|
Copyright © 2004 Quest Software Inc.. All rights reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |