ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

Video::PSXStreamDecoder::PSXVideoTrack Class Reference

Inheritance diagram for Video::PSXStreamDecoder::PSXVideoTrack:
Collaboration diagram for Video::PSXStreamDecoder::PSXVideoTrack:

List of all members.

Public Member Functions

 PSXVideoTrack (Common::SeekableReadStream *firstSector, CDSpeed speed, int frameCount)
 ~PSXVideoTrack ()
uint16 getWidth () const
 Get the width of this track.
uint16 getHeight () const
 Get the height of this track.
Graphics::PixelFormat getPixelFormat () const
 Get the pixel format of this track.
bool endOfTrack () const
 Return if the track has finished.
int getCurFrame () const
 Get the current frame of this track.
int getFrameCount () const
 Get the frame count of this track.
uint32 getNextFrameStartTime () const
 Get the start time of the next frame in milliseconds since the start of the video.
const Graphics::SurfacedecodeNextFrame ()
 Decode the next frame.
void setEndOfTrack ()
void decodeFrame (Common::BitStreamMemoryStream *frame, uint sectorCount)

Private Types

enum  PlaneType { kPlaneY = 0, kPlaneU = 1, kPlaneV = 2 }

Private Member Functions

void decodeMacroBlock (Common::BitStreamMemory16LEMSB *bits, int mbX, int mbY, uint16 scale, uint16 version)
void decodeBlock (Common::BitStreamMemory16LEMSB *bits, byte *block, int pitch, uint16 scale, uint16 version, PlaneType plane)
void readAC (Common::BitStreamMemory16LEMSB *bits, int *block)
int readDC (Common::BitStreamMemory16LEMSB *bits, uint16 version, PlaneType plane)
void dequantizeBlock (int *coefficients, float *block, uint16 scale)
void idct (float *dequantData, float *result)
int readSignedCoefficient (Common::BitStreamMemory16LEMSB *bits)

Private Attributes

Graphics::Surface_surface
uint32 _frameCount
Audio::Timestamp _nextFrameStartTime
bool _endOfTrack
int _curFrame
uint16 _macroBlocksW
uint16 _macroBlocksH
byte_yBuffer
byte_cbBuffer
byte_crBuffer
Common::Huffman_acHuffman
Common::Huffman_dcHuffmanLuma
Common::Huffman_dcHuffmanChroma
int _lastDC [3]

Detailed Description

Definition at line 78 of file psx_decoder.h.


Member Enumeration Documentation

Enumerator:
kPlaneY 
kPlaneU 
kPlaneV 

Definition at line 102 of file psx_decoder.h.


Constructor & Destructor Documentation

Video::PSXStreamDecoder::PSXVideoTrack::PSXVideoTrack ( Common::SeekableReadStream firstSector,
CDSpeed  speed,
int  frameCount 
)

Definition at line 424 of file psx_decoder.cpp.

Video::PSXStreamDecoder::PSXVideoTrack::~PSXVideoTrack (  ) 

Definition at line 446 of file psx_decoder.cpp.


Member Function Documentation

void Video::PSXStreamDecoder::PSXVideoTrack::decodeBlock ( Common::BitStreamMemory16LEMSB bits,
byte block,
int  pitch,
uint16  scale,
uint16  version,
PlaneType  plane 
) [private]

Definition at line 674 of file psx_decoder.cpp.

void Video::PSXStreamDecoder::PSXVideoTrack::decodeFrame ( Common::BitStreamMemoryStream frame,
uint  sectorCount 
)

Definition at line 466 of file psx_decoder.cpp.

void Video::PSXStreamDecoder::PSXVideoTrack::decodeMacroBlock ( Common::BitStreamMemory16LEMSB bits,
int  mbX,
int  mbY,
uint16  scale,
uint16  version 
) [private]

Definition at line 501 of file psx_decoder.cpp.

const Graphics::Surface * Video::PSXStreamDecoder::PSXVideoTrack::decodeNextFrame (  )  [virtual]

Decode the next frame.

Implements Video::VideoDecoder::VideoTrack.

Definition at line 462 of file psx_decoder.cpp.

void Video::PSXStreamDecoder::PSXVideoTrack::dequantizeBlock ( int *  coefficients,
float *  block,
uint16  scale 
) [private]

Definition at line 538 of file psx_decoder.cpp.

bool Video::PSXStreamDecoder::PSXVideoTrack::endOfTrack (  )  const [inline, virtual]

Return if the track has finished.

Reimplemented from Video::VideoDecoder::VideoTrack.

Definition at line 86 of file psx_decoder.h.

int Video::PSXStreamDecoder::PSXVideoTrack::getCurFrame (  )  const [inline, virtual]

Get the current frame of this track.

See also:
VideoDecoder::getCurFrame()

Implements Video::VideoDecoder::VideoTrack.

Definition at line 87 of file psx_decoder.h.

int Video::PSXStreamDecoder::PSXVideoTrack::getFrameCount (  )  const [inline, virtual]

Get the frame count of this track.

Note:
If the frame count is unknown, return 0 (which is also the default implementation of the function). However, one must also implement endOfTrack() in that case.

Reimplemented from Video::VideoDecoder::VideoTrack.

Definition at line 88 of file psx_decoder.h.

uint16 Video::PSXStreamDecoder::PSXVideoTrack::getHeight (  )  const [inline, virtual]

Get the height of this track.

Implements Video::VideoDecoder::VideoTrack.

Definition at line 84 of file psx_decoder.h.

uint32 Video::PSXStreamDecoder::PSXVideoTrack::getNextFrameStartTime (  )  const [virtual]

Get the start time of the next frame in milliseconds since the start of the video.

Implements Video::VideoDecoder::VideoTrack.

Definition at line 458 of file psx_decoder.cpp.

Graphics::PixelFormat Video::PSXStreamDecoder::PSXVideoTrack::getPixelFormat (  )  const [inline, virtual]

Get the pixel format of this track.

Implements Video::VideoDecoder::VideoTrack.

Definition at line 85 of file psx_decoder.h.

uint16 Video::PSXStreamDecoder::PSXVideoTrack::getWidth (  )  const [inline, virtual]

Get the width of this track.

Implements Video::VideoDecoder::VideoTrack.

Definition at line 83 of file psx_decoder.h.

void Video::PSXStreamDecoder::PSXVideoTrack::idct ( float *  dequantData,
float *  result 
) [private]

Definition at line 635 of file psx_decoder.cpp.

void Video::PSXStreamDecoder::PSXVideoTrack::readAC ( Common::BitStreamMemory16LEMSB bits,
int *  block 
) [private]

Definition at line 578 of file psx_decoder.cpp.

int Video::PSXStreamDecoder::PSXVideoTrack::readDC ( Common::BitStreamMemory16LEMSB bits,
uint16  version,
PlaneType  plane 
) [private]

Definition at line 548 of file psx_decoder.cpp.

int Video::PSXStreamDecoder::PSXVideoTrack::readSignedCoefficient ( Common::BitStreamMemory16LEMSB bits  )  [private]

Definition at line 613 of file psx_decoder.cpp.

void Video::PSXStreamDecoder::PSXVideoTrack::setEndOfTrack (  )  [inline]

Definition at line 92 of file psx_decoder.h.


Member Data Documentation

Definition at line 100 of file psx_decoder.h.

Definition at line 99 of file psx_decoder.h.

Definition at line 118 of file psx_decoder.h.


The documentation for this class was generated from the following files:


Generated on Sat Mar 16 2019 05:07:23 for ResidualVM by doxygen 1.7.1
curved edge   curved edge