Package org.axsl.graphic

Examples of org.axsl.graphic.GraphicException


                } else {
                    break;
                }
            }
        } catch (final IOException ex) {
            throw new GraphicException("Error while loading image " +
                    getUrl().toString() + " : " + ex.getClass() +
                    " - " + ex.getMessage());
        }
        this.fileContents = baos.toByteArray();
    }
View Full Code Here


            + getUrl().toString() + " : ";
        if (e != null) {
            message += e.getClass() + " - " + e.getMessage();

        }
        throw new GraphicException(message);
    }
View Full Code Here

        } else if (getBitDepth() == BIT_DEPTH_4
                || getBitDepth() == BIT_DEPTH_GRAYSCALE) {
            bytesPerRow = this.pixelWidth * getBitDepth() /
                    WKConstants.BITS_PER_BYTE;
        } else {
            throw new GraphicException("Image (" + getUrl().toString()
                    + ") has " + getBitDepth()
                    + " which is not a supported BMP format.");
        }
        if ((bytesPerRow & BMPGraphic.BITS_1_AND_2_MASK) != 0) {
            bytesPerRow |= BMPGraphic.BITS_1_AND_2_MASK;
View Full Code Here

    /**
     * {@inheritDoc}
     */
    public byte[] getRawSamples() throws GraphicException {
        /* TODO: Add support for this feature. */
        throw new GraphicException("Unsupported feature getRawSamples() in "
                + this.getClass().getName() + "for: "
                + this.getUrl().toExternalForm());
    }
View Full Code Here

     * has an error.
     */
    public boolean isImageReady() throws GraphicException {
        synchronized (this.imageStatus) {
            if (this.imageStatus.intValue() == ImageConsumer.IMAGEABORTED) {
                throw new GraphicException("Image aborted");
            }
            if (this.imageStatus.intValue() == ImageConsumer.IMAGEERROR) {
                throw new GraphicException("Image error");
            }

            if (this.imageStatus.intValue() == ImageConsumer.STATICIMAGEDONE
                    || this.imageStatus.intValue()
                    == ImageConsumer.SINGLEFRAMEDONE) {
View Full Code Here

        pg.setHints(this.hints);
        pg.setProperties(this.properties);
        try {
            pg.grabPixels();
        } catch (final InterruptedException intex) {
            throw new GraphicException("Image grabbing interrupted : "
                                + intex.getMessage());
        }
        return tmpMap;
    }
View Full Code Here

                } else {
                    break;
                }
            }
        } catch (final IOException ex) {
            throw new GraphicException("Error while loading image " +
                    getUrl().toString() + " : " + ex.getClass() +
                    " - " + ex.getMessage());
        }
        setContent(baos.toByteArray());
    }
View Full Code Here

TOP

Related Classes of org.axsl.graphic.GraphicException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.