Age | Commit message (Collapse) | Author |
|
These issues were identified by the STACK tool.
By default, the C++ new operator will throw an exception on allocation
failure, rather than returning a null pointer.
The result is that testing the returned pointer for null is redundant
and _may_ be removed by the compiler. This is thus optimization
unstable and may result in incorrect behaviour at runtime.
However, we do not use exceptions as they are not supported by all
compilers and may be disabled.
To make this stable without removing the null check, you could qualify
the new operator call with std::nothrow to indicate that this should
return a null, rather than throwing an exception.
However, using (std::nothrow) was not desirable due to the Symbian
toolchain lacking a <new> header.
A global solution to this was also not easy by redefining "new" as "new
(std::nothrow)" due to custom constructors in NDS toolchain and various
common classes.
Also, this would then need explicit checks for OOM adding to all new
usages as per C malloc which is untidy.
For now to remove this optimisation unstable code is best as it is
likely to not be present anyway, and OOM will cause a system library
exception instead, even without exceptions enabled in the application
code.
|
|
|
|
|
|
|
|
Add support for QuickTime Music playback
|
|
|
|
|
|
|
|
Powered by:
git ls-files "*.cpp" "*.h" "*.m" "*.mm" | xargs sed -i -e 's/[ \t]*$//'
|
|
|
|
|
|
VideoDecoder upgrade & partial rewrite
|
|
|
|
|
|
This also adds an omitted _decodedSampleCount initialization in Oki
ADPCM decoder.
|
|
|
|
|
|
invalid VOC files.
Formerly when an unsupported block was found the opening would fail. Instead
now all the valid blocks till that occasion will be played.
This fixes an missing sound in Full Throttle (thanks to clone2727 for
reporting), which is using a VOC file which fails to specify the proper block
length for its sound block.
|
|
|
|
|
|
This was only used by the RDFT code, now replaced by Common::RDFT.
|
|
|
|
The Bitstream format is changed to 32LELSB and an error in the getVlc2()
function bitstream reading needed to be corrected to fix operation.
|
|
This should allow the QDM2 codec to work again with Common::Bitstream
instead of the older getBits() reader, but this aborts with a reading
past end of stream error...
|
|
This is to allow modification of the code which needs to assign the
data member of the sub_packet structure to an offset in the input
byte readStream.
|
|
getBits(n) would cause a runtime error if n is greater than 32,
but using getBits() to skip is no longer necessary as the newer
BitStream class has a skip method, which is used instead.
|
|
|
|
This removes the internal getBitContext bitwise reading code and
replaces with Common::BitStream.
However, this breaks the codec as in one location, the internal buffer
of getBitContext reader is used and this can't be directly replaced.
This will need to be understood and rewritten.
|
|
The number of channels in AAC can differ from the actual number of channels needed making us require this. The channel count inside the container is always the correct one.
|
|
|
|
This also cleans up the QuickTime audio code to make it a bit more manageable too
|
|
find -name '*.h' -or -name '*.cpp' | xargs sed -r -i 's@\(([A-Za-z0-9]+)\*\)@(\1 *)@g'
This seems to have caught some params as well which is not undesirable IMO.
It also caught some strings containing this which is undesirable so I
excluded them manually. (engines/sci/engine/kernel_tables.h)
|
|
The last incomplete packet is ignored
|
|
|
|
It seems the VOC files used by Simon 1 Amiga CD32 use 128 as terminator block.
Added this as a special case with a debug output when it's caught.
|
|
noticing.
|
|
|
|
MPEG-4 files don't contain any elst atom
|
|
|
|
|
|
|
|
Audio is now decoded in AudioStream classes instead of being decoded ahead of time and then queued.
|
|
This should fix missing sound in Touche.
|
|
|
|
This drops the (unused) ability to play based on a list of input blocks. This
was formely only used by the NDS specific VOC streaming code, which has been
removed in 9fa9f68789ef51e078cb8631e06bead13cae13f2.
|
|
|
|
Now all VOCs are streamed rather than preloaded. This deprecates the
STREAM_AUDIO_FROM_DISK define, which was previously used to stream VOCs from
disk.
This might very well break some engines which relied on the stream not being
changed after makeVOCStream! I adapted all engines which had a check for
STREAM_AUDIO_FROM_DISK in their code.
It would be wise to check all other engines using VOC to see if this might
cause any problems for them.
|
|
|
|
|
|
Also, remove two engines not using VOC from voc.h header.
|