Top Inners Fields Constructors Methods
com.sun.javafx.webkit.prism

pack-priv final Class WCImageDecoderImpl

extends WCImageDecoder
Class Inheritance
Imports
com.sun.javafx.iio.ImageFrame, .ImageLoadListener, .ImageLoader, .ImageMetadata, .ImageStorage, .ImageStorageException, com.sun.javafx.logging.PlatformLogger, .PlatformLogger.Level, com.sun.webkit.graphics.WCGraphicsManager, .WCImage, .WCImageDecoder, .WCImageFrame, java.io.ByteArrayInputStream, .IOException, .InputStream, java.util.Arrays, javafx.concurrent.Service, .Task

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Field Summary

Modifier and TypeField and Description
private volatile byte[]
private volatile int
private String
private int
private ImageFrame[]
private boolean
private boolean
private int
private PrismImage[]
private int
private Service<ImageFrame[]>
private static final PlatformLogger
private final ImageLoadListener
private static final ThreadLocal<int[]>

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
protected void
addImageData(byte[]
a portion of image data, or null if all data received
dataPortion
)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.addImageData.

Receives a portion of image data.

protected synchronized void
private void
protected String
protected synchronized WCImageFrame
getFrame(int
frame index
idx
)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrame.

Returns image frame at the specified index.

protected synchronized boolean
getFrameCompleteStatus(int
frame index
idx
)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameCompleteStatus.

Returns whether the frame is complete or partial

protected int
getFrameCount()

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameCount.

Returns a number of frames of the decoded image.

protected int
getFrameDuration(int
frame index
idx
)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameDuration.

Returns frame duration in ms

private synchronized ImageMetadata
protected int[]
getFrameSize(int
frame index
idx
)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameSize.

Returns frame size, array[0] represents width and array[1] represents height.

private synchronized ImageFrame
getImageFrame(int idx)

protected int[]
getImageSize()

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getImageSize.

Returns image size.

private synchronized PrismImage
getPrismImage(int idx, ImageFrame frame)

private boolean
private synchronized ImageFrame[]
private ImageFrame[]
protected void
private void
resizeDataArray(int newDataSize)

private synchronized void
private void

Field Detail

databack to summary
private volatile byte[] data
dataSizeback to summary
private volatile int dataSize
fileNameExtensionback to summary
private String fileNameExtension
frameCountback to summary
private int frameCount
framesback to summary
private ImageFrame[] frames
framesDecodedback to summary
private boolean framesDecoded
fullDataReceivedback to summary
private boolean fullDataReceived
imageHeightback to summary
private int imageHeight
imagesback to summary
private PrismImage[] images
imageWidthback to summary
private int imageWidth
loaderback to summary
private Service<ImageFrame[]> loader
logback to summary
private static final PlatformLogger log
readerListenerback to summary
private final ImageLoadListener readerListener
THREAD_LOCAL_SIZE_ARRAYback to summary
private static final ThreadLocal<int[]> THREAD_LOCAL_SIZE_ARRAY

Constructor Detail

WCImageDecoderImplback to summary
pack-priv WCImageDecoderImpl()

Method Detail

addImageDataback to summary
protected void addImageData(byte[] dataPortion)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.addImageData.

Doc from com.sun.webkit.graphics.WCImageDecoder.addImageData.

Receives a portion of image data.

Parameters
dataPortion:byte[]

a portion of image data, or null if all data received

Annotations
@Override
destroyback to summary
protected synchronized void destroy()

Implements abstract com.sun.webkit.graphics.WCImageDecoder.destroy.

Annotations
@Override
destroyLoaderback to summary
private void destroyLoader()
getFilenameExtensionback to summary
protected String getFilenameExtension()

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFilenameExtension.

Annotations
@Override
getFrameback to summary
protected synchronized WCImageFrame getFrame(int idx)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrame.

Doc from com.sun.webkit.graphics.WCImageDecoder.getFrame.

Returns image frame at the specified index.

Parameters
idx:int

frame index

Annotations
@Override
getFrameCompleteStatusback to summary
protected synchronized boolean getFrameCompleteStatus(int idx)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameCompleteStatus.

Doc from com.sun.webkit.graphics.WCImageDecoder.getFrameCompleteStatus.

Returns whether the frame is complete or partial

Parameters
idx:int

frame index

Annotations
@Override
getFrameCountback to summary
protected int getFrameCount()

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameCount.

Doc from com.sun.webkit.graphics.WCImageDecoder.getFrameCount.

Returns a number of frames of the decoded image.

Returns:int

a number of image frames

Annotations
@Override
getFrameDurationback to summary
protected int getFrameDuration(int idx)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameDuration.

Doc from com.sun.webkit.graphics.WCImageDecoder.getFrameDuration.

Returns frame duration in ms

Parameters
idx:int

frame index

Annotations
@Override
getFrameMetadataback to summary
private synchronized ImageMetadata getFrameMetadata(int idx)
getFrameSizeback to summary
protected int[] getFrameSize(int idx)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getFrameSize.

Doc from com.sun.webkit.graphics.WCImageDecoder.getFrameSize.

Returns frame size, array[0] represents width and array[1] represents height.

Parameters
idx:int

frame index

Annotations
@Override
getImageFrameback to summary
private synchronized ImageFrame getImageFrame(int idx)
getImageSizeback to summary
protected int[] getImageSize()

Implements abstract com.sun.webkit.graphics.WCImageDecoder.getImageSize.

Doc from com.sun.webkit.graphics.WCImageDecoder.getImageSize.

Returns image size.

Annotations
@Override
getPrismImageback to summary
private synchronized PrismImage getPrismImage(int idx, ImageFrame frame)
imageSizeAvilableback to summary
private boolean imageSizeAvilable()
loadFramesback to summary
private synchronized ImageFrame[] loadFrames(InputStream in)
loadFramesback to summary
private ImageFrame[] loadFrames()
loadFromResourceback to summary
protected void loadFromResource(String name)

Implements abstract com.sun.webkit.graphics.WCImageDecoder.loadFromResource.

Annotations
@Override
resizeDataArrayback to summary
private void resizeDataArray(int newDataSize)
setFramesback to summary
private synchronized void setFrames(ImageFrame[] frames)
startLoaderback to summary
private void startLoader()
com.sun.javafx.webkit.prism back to summary

private final Class WCImageDecoderImpl.Frame

extends WCImageFrame
Class Inheritance

Field Summary

Modifier and TypeField and Description
private WCImage

Constructor Summary

AccessConstructor and Description
private
Frame(WCImage image, String extension)

Method Summary

Modifier and TypeMethod and Description
protected void
public WCImage
public int[]
getSize()

Implements abstract com.sun.webkit.graphics.WCImageFrame.getSize.

Returns frame size, array[0] represents width and array[1] represents height.

Field Detail

imageback to summary
private WCImage image

Constructor Detail

Frameback to summary
private Frame(WCImage image, String extension)

Method Detail

destroyDecodedDataback to summary
protected void destroyDecodedData()

Overrides com.sun.webkit.graphics.WCImageFrame.destroyDecodedData.

Annotations
@Override
getFrameback to summary
public WCImage getFrame()

Implements abstract com.sun.webkit.graphics.WCImageFrame.getFrame.

Annotations
@Override
getSizeback to summary
public int[] getSize()

Implements abstract com.sun.webkit.graphics.WCImageFrame.getSize.

Doc from com.sun.webkit.graphics.WCImageFrame.getSize.

Returns frame size, array[0] represents width and array[1] represents height.

Annotations
@Override