| Commit message (Collapse) | Author | Age |
| |
|
|
|
| |
The compiler should be smart enough to optimize the modulo operation. Besides,
this code is only executed via fec_new(), which is not performance critical.
|
| |
|
|
| |
We have helpers for that.
|
| |
|
|
|
| |
Both are equivalent, but the latter is shorter and more performant because
it avoids a multiplication and a check for overflow.
|
| |
|
|
| |
We may as well call arr_alloc() directly.
|
| |
|
|
| |
A cup of dedox for fec.c and the new two-paragraph overview of the fec API.
|
| |
|
|
|
|
| |
Apart from the initialization code, there is only one user of the Galois
field exponential table. This user passes a value modulo GF_SIZE, so we
never access the second half of the array.
|
| |
|
|
| |
The fec code does not need the helpers from portable_io.h.
|
| |
|
|
| |
Every .c file includes it anyway.
|
| |
|
|
|
|
|
|
| |
Change all callers of alloc() which pass a product of two integers as
the allocation size to call the new function instead. This function
aborts if the multiplication overflows. With arr_alloc() in place,
alloc() reduces to a trivial wrapper which calls new arr_alloc()
with the first argument equal to one.
|
| |
|
|
|
| |
Reword the documentation a bit since the function has never been a
wrapper for calloc(3). No code changes.
|
| |
|
|
|
|
|
| |
Just because it's shorter and matches the naming of the new allocators
we are about to introduce. The bulk of this patch was created with
sed -i 's/para_malloc/alloc/g' *.c *.h yy/mp.y
|
| |
|
|
|
|
|
|
| |
This gets rid of gcc warnings of the form
warning: ISO C90 forbids mixed declarations and code
when compiled with -Wdeclaration-after-statement.
|
| |
|
|
| |
Probably does not matter much..
|
| |
|
|
| |
Fix fixes duplicate `const' warnings on gcc-3.3.3.
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
A wrapper for regcomp() that logs an error message if the regcomp() failed
and uses a return value according to the paraslash rules. Currently there is
only one user of regular expressions, is_v4_dot_quad(), which is converted
to para_regex(), but new callers will be added soon.
Unfortunately, this change made it necessary to include regex.h in all .c files
that use string.h. Clean up the order in which headers are included a bit while
we're at it.
Maybe I should rethink the rule "Only .c files shall include header files"...
|
| | |
|
| | |
|
| | |
|
| | |
|
|
|
This patch adds the first draft of a FEC implementation based
on code by Luigi Rizzo.
On the server side, the FEC encoding is done within the virtual
streaming system which also contains the timing routines for sending
a FEC-encoded audio stream. Senders my request such an encoded stream
by calling vss_add_fec_client() with a fec_client_parms structure
that contains the FEC parameters and a callback function which is used
to actually send the data.
On the receiver side, the new fecdec filter is introduced which must
be used to decode a FEC-encoded stream. As the fec parameters are
contained in the header of each data slice of the encoded stream, no
options to this filter are necessary.
ATM, FEC is only used by the udp sender/receiver, but other protocols
can be easily changed to use FEC as well.
This new code is still experimental, lacks documentation and the fec
parameters can currently only be changed by editing the source code.
|