From ad2bfc18d6c8450a66db50daad7fe5b8447f3838 Mon Sep 17 00:00:00 2001 From: Sven Hesse Date: Wed, 1 Aug 2007 01:20:02 +0000 Subject: Some GK2 VMDs now load and play, too. The sound is borked, though (probably 16 bit). svn-id: r28377 --- engines/gob/coktelvideo.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/engines/gob/coktelvideo.cpp b/engines/gob/coktelvideo.cpp index a8765c4a99..864a760ea8 100644 --- a/engines/gob/coktelvideo.cpp +++ b/engines/gob/coktelvideo.cpp @@ -868,7 +868,7 @@ bool Vmd::load(Common::SeekableReadStream &stream) { if (_hasVideo) { if (_frameDataSize == 0) _frameDataSize = _width * _height + 500; - if (_vidBufferSize) + if (_vidBufferSize == 0) _vidBufferSize = _frameDataSize; _frameData = new byte[_frameDataSize]; @@ -888,7 +888,7 @@ bool Vmd::load(Common::SeekableReadStream &stream) { if (_hasSound) { _features |= kFeaturesSound; - _soundSliceLength = 1000 / (_soundFreq / _soundSliceSize); + _soundSliceLength = (uint16) (1000.0 / ((double) _soundFreq / (double) _soundSliceSize)); _frameLength = _soundSliceLength; _soundStage = 1; -- cgit v1.2.3