avcodec/j2kenc: Remove dead, disabled debug code

Seems to have never worked, even when this was added in
83654c7b1b.

Reviewed-by: Rémi Denis-Courmont <remi@remlab.net>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
Andreas Rheinhardt
2025-11-21 14:18:05 +01:00
parent 2a90e7d725
commit 0eb423866f

View File

@@ -148,76 +148,6 @@ typedef struct {
} Jpeg2000EncoderContext;
/* debug */
#if 0
#undef ifprintf
#undef printf
static void nspaces(FILE *fd, int n)
{
while(n--) putc(' ', fd);
}
static void printcomp(Jpeg2000Component *comp)
{
int i;
for (i = 0; i < comp->y1 - comp->y0; i++)
ff_jpeg2000_printv(comp->i_data + i * (comp->x1 - comp->x0), comp->x1 - comp->x0);
}
static void dump(Jpeg2000EncoderContext *s, FILE *fd)
{
int tileno, compno, reslevelno, bandno, precno;
fprintf(fd, "XSiz = %d, YSiz = %d, tile_width = %d, tile_height = %d\n"
"numXtiles = %d, numYtiles = %d, ncomponents = %d\n"
"tiles:\n",
s->width, s->height, s->tile_width, s->tile_height,
s->numXtiles, s->numYtiles, s->ncomponents);
for (tileno = 0; tileno < s->numXtiles * s->numYtiles; tileno++){
Jpeg2000Tile *tile = s->tile + tileno;
nspaces(fd, 2);
fprintf(fd, "tile %d:\n", tileno);
for(compno = 0; compno < s->ncomponents; compno++){
Jpeg2000Component *comp = tile->comp + compno;
nspaces(fd, 4);
fprintf(fd, "component %d:\n", compno);
nspaces(fd, 4);
fprintf(fd, "x0 = %d, x1 = %d, y0 = %d, y1 = %d\n",
comp->x0, comp->x1, comp->y0, comp->y1);
for(reslevelno = 0; reslevelno < s->nreslevels; reslevelno++){
Jpeg2000ResLevel *reslevel = comp->reslevel + reslevelno;
nspaces(fd, 6);
fprintf(fd, "reslevel %d:\n", reslevelno);
nspaces(fd, 6);
fprintf(fd, "x0 = %d, x1 = %d, y0 = %d, y1 = %d, nbands = %d\n",
reslevel->x0, reslevel->x1, reslevel->y0,
reslevel->y1, reslevel->nbands);
for(bandno = 0; bandno < reslevel->nbands; bandno++){
Jpeg2000Band *band = reslevel->band + bandno;
nspaces(fd, 8);
fprintf(fd, "band %d:\n", bandno);
nspaces(fd, 8);
fprintf(fd, "x0 = %d, x1 = %d, y0 = %d, y1 = %d,"
"codeblock_width = %d, codeblock_height = %d cblknx = %d cblkny = %d\n",
band->x0, band->x1,
band->y0, band->y1,
band->codeblock_width, band->codeblock_height,
band->cblknx, band->cblkny);
for (precno = 0; precno < reslevel->num_precincts_x * reslevel->num_precincts_y; precno++){
Jpeg2000Prec *prec = band->prec + precno;
nspaces(fd, 10);
fprintf(fd, "prec %d:\n", precno);
nspaces(fd, 10);
fprintf(fd, "xi0 = %d, xi1 = %d, yi0 = %d, yi1 = %d\n",
prec->xi0, prec->xi1, prec->yi0, prec->yi1);
}
}
}
}
}
}
#endif
/* bitstream routines */
/** put n times val bit */