mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-02 23:26:44 +00:00
VIDEO: YUV420 conversion for MKV decoder
This commit is contained in:
parent
4613ab0fd9
commit
b3dfca3cb1
@ -355,6 +355,9 @@ void MKVDecoder::readNextPacket() {
|
||||
if (img->fmt != VPX_IMG_FMT_I420)
|
||||
error("Movie error. The movie is not in I420 colour format, which is the only one I can hanlde at the moment.");
|
||||
|
||||
|
||||
YUVToRGBMan.convert420(&_displaySurface, Graphics::YUVToRGBManager::kScaleITU, img->planes[0], img->planes[1], img->planes[2], img->d_w, img->d_h, img->stride[0], img->stride[1]);
|
||||
|
||||
unsigned int y;
|
||||
#if 0
|
||||
GLubyte *ytex = NULL;
|
||||
@ -437,6 +440,7 @@ MKVDecoder::VPXVideoTrack::~VPXVideoTrack() {
|
||||
}
|
||||
|
||||
bool MKVDecoder::VPXVideoTrack::decodePacket(ogg_packet &_oggPacket) {
|
||||
warning("VPXVideoTrack::decodePacket()");
|
||||
if (th_decode_packetin(_theoraDecode, &_oggPacket, 0) == 0) {
|
||||
_curFrame++;
|
||||
|
||||
@ -588,6 +592,8 @@ static double rint(double v) {
|
||||
#endif
|
||||
|
||||
bool MKVDecoder::VorbisAudioTrack::decodeSamples(ogg_packet &oggPacket) {
|
||||
return true;
|
||||
|
||||
if(!vorbis_synthesis(&vorbisBlock, &oggPacket) ) {
|
||||
if (vorbis_synthesis_blockin(&vorbisDspState, &vorbisBlock))
|
||||
warning("Vorbis Synthesis block in error");
|
||||
|
@ -176,6 +176,8 @@ private:
|
||||
|
||||
int videoTrack = -1;
|
||||
int audioTrack = -1;
|
||||
|
||||
Graphics::Surface _displaySurface;
|
||||
};
|
||||
|
||||
} // End of namespace Video
|
||||
|
Loading…
Reference in New Issue
Block a user