Commit Graph

26 Commits

Author SHA1 Message Date
Bastien Bouclet
955e18c648 COMMON: Use nullptr instead of NULL or 0 where appropriate 2018-05-10 08:35:46 +02:00
Bastien Bouclet
8547c89b86 VIDEO: Change QT edit list to a Common::Array
And fix an out of bounds acces when seeking to the end of a video.
Skipping samples is needed even when seeking through silent edits
because a silent stream is queued for those.

Fixes #10219.
2017-09-21 13:06:18 +02:00
Matthew Hoops
9630753861 COMMON: Move some QuickTime Track variables into SampleDesc where they belong 2014-03-18 19:12:20 -04:00
D G Turner
ac4087856f ALL: Remove optimization unstable code on checking for null after new.
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.
2014-01-15 02:36:19 +00:00
Einar Johan Trøan Sømåen
5d4d65d6d9 JANITORIAL: Fix ){ -> ) { 2013-01-24 20:15:13 +01:00
Matthew Hoops
4a458236f6 COMMON: Make QuickTimeParser::readSampleDesc take the desc size 2012-09-09 13:47:40 -04:00
Matthew Hoops
bbf0bbcd64 COMMON: Allow for parsing QuickTime MIDI files 2012-09-05 22:57:10 -04:00
Matthew Hoops
ed4232cfeb COMMON: Skip junk found at the end of QuickTime files
Can occur in files and is ignored by QuickTime
2012-05-21 18:57:18 -04:00
Matthew Hoops
68e1a04183 AUDIO: Fix QDM2 extra data parsing 2012-03-30 14:40:14 -04:00
Matthew Hoops
7c4787e0dc COMMON: Read in QuickTime extra data for SVQ3 2012-03-30 13:39:48 -04:00
Matthew Hoops
ee0a05c32e COMMON: Add a dummy edit when a QuickTime file contains none
The edit just takes up the entire length of the track
2012-03-19 11:08:36 -04:00
Matthew Hoops
f17b1bf4f0 COMMON: Fix opening QuickTime files from MacBinary files 2012-02-27 18:31:20 -05:00
Matthew Hoops
7ac5bcd6f1 COMMON: QuickTime mdat atoms should be leaves 2011-12-15 12:59:42 -05:00
Matthew Hoops
b367772b5f VIDEO: Add support for QuickTime video track edit lists 2011-12-12 12:28:48 -05:00
Christoph Mallon
84220d2ca0 COMMON: Remove superfluous Common:: qualifiers. 2011-08-07 15:19:07 +02:00
Eugene Sandulenko
2fa17c44ed JANITORIAL: Remove SVN keywords 2011-08-06 11:30:47 +01:00
Max Horn
88913c0139 ALL: Remove trailing whitespaces
This tries to make our code a bit more compliant with our code formatting
conventions. For future use, this is the command I used:
  git ls-files "*.cpp" "*.h" | xargs sed -i -e 's/[ \t]*$//'
2011-06-20 00:59:48 +02:00
Matthew Hoops
547fd1bdca COMMON: Cleanup QuickTime variable and struct naming 2011-06-03 00:58:29 -04:00
Matthew Hoops
2e06681698 COMMON: Begin objectifying QuickTimeParser::SampleDesc further
This is preparation for multiple video and audio tracks
2011-06-02 23:44:40 -04:00
Matthew Hoops
a1d41da096 Merge remote branch 'upstream/master' into t7g-ios
Conflicts:
	audio/decoders/qdm2.h
	common/util.cpp
	engines/groovie/music.cpp
	engines/groovie/resource.h
	video/qt_decoder.cpp
	video/qt_decoder.h
2011-05-11 00:30:28 -04:00
Matthew Hoops
6d153f311c Merge remote branch 'upstream/master' into t7g-ios
Conflicts:
	video/qt_decoder.cpp
2011-04-13 16:04:29 -04:00
Matthew Hoops
4366f3632c COMMON: Cleanup QuickTime's readSTTS() 2011-04-12 14:01:42 -04:00
Matthew Hoops
4a39baa095 COMMON: Fix QuickTime track duration 2011-04-10 21:11:02 -04:00
Matthew Hoops
7c5dfaa04c COMMON: Parse the MPEG-4 esds atom 2011-04-08 22:46:19 -04:00
Matthew Hoops
faee277978 COMMON: Add a DisposeAfterUse flag to QuickTimeParser 2011-04-08 17:04:29 -04:00
Matthew Hoops
db71efd94f VIDEO: Split the QuickTime parser from the QuickTime VideoDecoder 2011-04-07 00:21:48 -04:00