[FFmpeg-devel] [PATCH 2/5] truehd: break out part of rematrix_channels into platform-specific callback.

Michael Niedermayer michaelni at gmx.at
Thu Mar 20 18:03:37 CET 2014


On Thu, Mar 20, 2014 at 04:06:12PM -0000, Ben Avison wrote:
> On Thu, 20 Mar 2014 15:21:04 -0000, Michael Niedermayer <michaelni at gmx.at> wrote:
> >I think Christophe meant the s->channel_params[channel].coeff in
> >mlp_filter_channel()
> >
> >I meant the matrix_coeff in rematrix_channels()
> 
> Good point, yes. But it's a very similar situation - repeated multiply-
> accumulates of a (changing) array of 32-bit values by a (relatively
> constant) array of values which are currently 32-bit but could fit into
> signed 16-bit values. The interleaved pattern of loads and multiply-
> accumulates I generate are basically the same too, as the same interlocks
> apply.
> 
> >what i meant was that many of the values look like they might fit into
> >32bit arithmetic, avoiding the need for dealing with 64bit results
> >that is when the coefficients are shfted down
> 
> rematrix_channels does (accum >> 14) afterwards though, so unlike
> mlp_filter_channel (where sometimes the post-accumulate shift is 0) I
> think you always need the upper 32 bits of the product.

the lsbs of the matrix coeffs are 0 in many cases or at least many of
the ones ive seen so far, thus the coeffs can be shifted down and
the result of the accumulation shifted up which is equivalent to
shifting by less than 14



> 
> >>Well, the matrices I can see look more like
> >>
> >>/ F880, 05C0, 0000, FE40, C000, 0000 \
> >>| 08E0, F8E0, 00C0, FF80, 1040, C000 |
> >>| D900, C600, C000, FD00, DB00, CF00 |
> >>| 0000, C000, D2B0, 0000, 0000, C000 |
> >>\ C000, 0CD4, DBC4, 0000, C000, 0CD4 /
> >
> >Is this for a real world file or some reference file ?
> 
> That particular example was from a ripped Blu-Ray, as it happens.
> 
> Ben
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

it is not once nor twice but times without number that the same ideas make
their appearance in the world. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140320/24fcfa72/attachment.asc>


More information about the ffmpeg-devel mailing list