Hello, I'm trying to modify the residue vectors in Vorbis audio files at encoding time. For testing, I'm just adding +1 to each residue vector's element, so e.g., if I have an original residue vector of [0,1,2,3] I modify it during the encoding to be [1,2,3,4], and at the decoder's side I should receive the [1,2,3,4] vector. The problem is that, after adding the +1, I still receive the vector [0,1,2,3]. I'm making this +1 to each element in a simple for loop for each channel, immediatly before the line number 700 of mapping0.c (just before calling _vp_couple): for(count=0; count<psy_look->n; count++) { vb->pcm[i][count] += 1; } Obviously, there is some place after in the code where my changes are being overwritten or somehow discarded, but I am being unable to find it (I thought it would be where a comment line says "couple_bundle is destructively overwritten by the class function if some but not all of the channels are marked as silence; build a fresh copy", but there is no silence in any channel). Could someone give me a hint on what may be happening, where my changes are being lost or where should I modify the residual vectors... anything. Thank you. PS: If it is important, I'm using quality level 6+ to force lossless coupling (AFAIK, 6+ quality levels are the ones with lossless coupling, right?).
Hm... and I'm working on the 1.2.3 libvorbis release. The line number reference might be useless with that info :) Jes?s D?az Vico escribi?:> Hello, > > I'm trying to modify the residue vectors in Vorbis audio files at > encoding time. For testing, I'm just adding +1 to each residue vector's > element, so e.g., if I have an original residue vector of [0,1,2,3] I > modify it during the encoding to be [1,2,3,4], and at the decoder's side > I should receive the [1,2,3,4] vector. The problem is that, after adding > the +1, I still receive the vector [0,1,2,3]. > > I'm making this +1 to each element in a simple for loop for each > channel, immediatly before the line number 700 of mapping0.c (just > before calling _vp_couple): > > for(count=0; count<psy_look->n; count++) { > vb->pcm[i][count] += 1; > } > > Obviously, there is some place after in the code where my changes are > being overwritten or somehow discarded, but I am being unable to find it > (I thought it would be where a comment line says "couple_bundle is > destructively overwritten by the class function if some but not all of > the channels are marked as silence; build a fresh copy", but there is no > silence in any channel). > > Could someone give me a hint on what may be happening, where my changes > are being lost or where should I modify the residual vectors... anything. > > Thank you. > > PS: If it is important, I'm using quality level 6+ to force lossless > coupling (AFAIK, 6+ quality levels are the ones with lossless coupling, > right?). >