org.jcodec.codecs.prores
Class ProresDecoder

java.lang.Object
  extended by org.jcodec.codecs.prores.ProresDecoder
All Implemented Interfaces:
VideoDecoder
Direct Known Subclasses:
ProresToThumb, ProresToThumb2x2, ProresToThumb4x4

public class ProresDecoder
extends Object
implements VideoDecoder

This class is part of JCodec ( www.jcodec.org ) This software is distributed under FreeBSD License Decoder for Apple ProRes format As posted at http://git.videolan.org/?p=ffmpeg.git;a=commitdiff;h=5554d e13b29b9bb812ee5cfd606349873ddf0945

Author:
The JCodec project

Constructor Summary
ProresDecoder()
           
 
Method Summary
 Picture[] decodeFields(ByteBuffer data, int[][][] target)
           
 Picture decodeFrame(ByteBuffer data, int[][] target)
          Decodes a video frame to an uncompressed picture in codec native colorspace
protected  int[] decodeOnePlane(BitReader bits, int blocksPerSlice, int[] qMat, int[] scan, int mbX, int mbY, int plane)
           
protected  void decodePicture(ByteBuffer data, int[][] result, int width, int height, int mbWidth, int[] qMatLuma, int[] qMatChroma, int[] scan, int pictureType, int chromaType)
           
static int golumbSign(int val)
           
static int golumbToSigned(int val)
           
 boolean isProgressive(ByteBuffer data)
           
static int nZeros(int check14Bit)
           
 int probe(ByteBuffer data)
          Tests if compressed frame can be decoded with this decoder
protected  void putSlice(int[][] result, int lumaStride, int mbX, int mbY, int[] y, int[] u, int[] v, int dist, int shift, int chromaType)
           
protected static void readACCoeffs(BitReader bits, int[] qMat, int[] out, int blocksPerSlice, int[] scan, int max, int log2blkSize)
           
static int readCodeword(BitReader reader, Codebook codebook)
           
static void readDCCoeffs(BitReader bits, int[] qMat, int[] out, int blocksPerSlice, int blkSize)
           
static ProresConsts.FrameHeader readFrameHeader(ByteBuffer inp)
           
static ProresConsts.PictureHeader readPictureHeader(ByteBuffer inp)
           
static int[] scaleMat(int[] qMatLuma, int qScale)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProresDecoder

public ProresDecoder()
Method Detail

nZeros

public static final int nZeros(int check14Bit)

readCodeword

public static final int readCodeword(BitReader reader,
                                     Codebook codebook)

golumbToSigned

public static final int golumbToSigned(int val)

golumbSign

public static final int golumbSign(int val)

readDCCoeffs

public static final void readDCCoeffs(BitReader bits,
                                      int[] qMat,
                                      int[] out,
                                      int blocksPerSlice,
                                      int blkSize)

readACCoeffs

protected static final void readACCoeffs(BitReader bits,
                                         int[] qMat,
                                         int[] out,
                                         int blocksPerSlice,
                                         int[] scan,
                                         int max,
                                         int log2blkSize)

decodeOnePlane

protected int[] decodeOnePlane(BitReader bits,
                               int blocksPerSlice,
                               int[] qMat,
                               int[] scan,
                               int mbX,
                               int mbY,
                               int plane)

decodeFrame

public Picture decodeFrame(ByteBuffer data,
                           int[][] target)
Description copied from interface: VideoDecoder
Decodes a video frame to an uncompressed picture in codec native colorspace

Specified by:
decodeFrame in interface VideoDecoder
Parameters:
data - Compressed frame data

decodeFields

public Picture[] decodeFields(ByteBuffer data,
                              int[][][] target)

readFrameHeader

public static ProresConsts.FrameHeader readFrameHeader(ByteBuffer inp)

decodePicture

protected void decodePicture(ByteBuffer data,
                             int[][] result,
                             int width,
                             int height,
                             int mbWidth,
                             int[] qMatLuma,
                             int[] qMatChroma,
                             int[] scan,
                             int pictureType,
                             int chromaType)

readPictureHeader

public static ProresConsts.PictureHeader readPictureHeader(ByteBuffer inp)

scaleMat

public static final int[] scaleMat(int[] qMatLuma,
                                   int qScale)

putSlice

protected void putSlice(int[][] result,
                        int lumaStride,
                        int mbX,
                        int mbY,
                        int[] y,
                        int[] u,
                        int[] v,
                        int dist,
                        int shift,
                        int chromaType)

isProgressive

public boolean isProgressive(ByteBuffer data)

probe

public int probe(ByteBuffer data)
Description copied from interface: VideoDecoder
Tests if compressed frame can be decoded with this decoder

Specified by:
probe in interface VideoDecoder
Parameters:
data - Compressed frame data
Returns:


Copyright © 2013. All Rights Reserved.