- Mar 09, 2025
-
-
Petter Reinholdtsen authored
The last iteration of the loop execute 1<<63, which would push the result into the signed bit of a signed 64 bit type, and this move into currently undefined behaviour with C99. Avoid the issue by making the operation work on unsigned 64 bit type instead. This require libogg version to 1.3.4, raise autotools dependency check to look for this. Partly solves github issue #18.
-
Petter Reinholdtsen authored
Use multiplication instead, allowing the compiler to optimize to bitshifts if it believe it to be safe. Partly solves github issue #18.
-
- Mar 07, 2025
-
-
Petter Reinholdtsen authored
The header used signed char _bf[256], make sure the method uses the same. Adjust pointer arithmetic to use array notation to make operation explicit. Avoid the following compiler message: ../../lib/state.c:1056:15: warning: argument 2 of type 'signed char *' declared as a pointer [-Warray-parameter=] 1056 | signed char *_bv,int _refi,int _pli,int _fragy0,int _fragy_end){ | ~~~~~~~~~~~~~^~~ In file included from ../../lib/state.c:20: ../../lib/state.h:526:14: note: previously declared as an array 'signed char[256]' 526 | signed char _bv[256],int _refi,int _pli,int _fragy0,int _fragy_end); | ~~~~~~~~~~~~^~~~~~~~
-
- Oct 31, 2014
-
-
Timothy B. Terriberry authored
oc_mb_fill_cmapping11() was defined without the last two parameters of its fellow mapping functions, meaning it got called with extra undeclared parameters. This could confuse the emscripten JavaScript cross-compiler's asm.js optimizations, as it's very picky about function signatures. Fixes #2068. Patch by Brion Vibber <brion@pobox.com>. svn path=/trunk/theora/; revision=19261
-
- Jan 08, 2013
-
-
Timothy B. Terriberry authored
Newer versions of png.h don't include it for us. This is only needed when compiling with OC_DUMP_IMAGES (i.e., for debugging). svn path=/trunk/theora/; revision=18760
-
- Mar 02, 2012
-
-
Timothy B. Terriberry authored
ref_frame_data was being allocated with the aligned allocator, but freed with the normal _ogg_free() function on failure, which doesn't work. This would only cause a problem if there was just enough memory to satisfy the reference frame allocation (just over 4.5 or 9 bytes per pixel) but not enough for the fragment buffer offets (1/16 or 1/8th byte per pixel). svn path=/trunk/theora/; revision=18219
-
- Dec 16, 2010
-
-
Ralph Giles authored
The specification says that the frame rate numerator and denominator MUST both be greater than zero. This wasn't checked as part of the structure validation code, and in fact passing a zero value here caused a segfault. The code now checks for this in oc_state_init() and returns TH_EINVAL, which is causes th_encode_alloc() and oc_decode_alloc() to return NULL. A check for that NULL return is also added to encoder_example.c to show that it may fail when an invalid th_info parameter is passed. svn path=/trunk/theora/; revision=17760
-
- Oct 29, 2010
-
-
Timothy B. Terriberry authored
Signed/unsigned comparison and integer conversion overflow. svn path=/trunk/theora/; revision=17576
-
- Oct 25, 2010
-
-
Timothy B. Terriberry authored
We don't actually use this for anything yet, but it may help calling applications (e.g., doing software YUV2RGB conversion). Also, change ref_frame_data to point directly to the desired reference frame, rather than require a lookup through ref_frame_idx first. This saves an indirection and gives a 0.7% speed-up at 720p on a Cortex A8. It should have an even bigger benefit on C64x, though it wasn't benchmarked there. svn path=/trunk/theora/; revision=17563
-
- Oct 12, 2010
-
-
Timothy B. Terriberry authored
Coverity thinks we're overrunning this static array by passing it to memset. In reality, it's a multidimensional array, and guaranteed to be contiguous, but we might as well silence this warning. Reported in https://bugzilla.mozilla.org/show_bug.cgi?id=559343 svn path=/trunk/theora/; revision=17505
-
- Sep 24, 2010
-
-
Timothy B. Terriberry authored
This avoids repeatedly performing the MB mode -> reference frame translation, which is done many times per fragment during DC prediction. In fact, by using a special OC_FRAME_NONE tag for uncoded fragments, one need not even check to see if a fragment is coded during DC prediction, simplifying it even more. This saves 2% on 720p decode on a Cortex A8. svn path=/trunk/theora/; revision=17457
-
- Sep 23, 2010
-
-
Ralph Giles authored
This will be the basis of the 1.2.x releases. svn path=/trunk/theora/; revision=17445
-