Skip to content

Commit

Permalink
dd: remove debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
alfredh committed Jul 30, 2024
1 parent 65093a6 commit 2f73e19
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 30 deletions.
9 changes: 0 additions & 9 deletions src/dd/dd.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,6 @@ static int template_dtis(struct dd *dd, struct getbit *gb)

static int template_fdiffs(struct dd *dd, struct getbit *gb)
{
re_printf("template_fdiffs\n");

for (uint8_t templateIndex = 0;
templateIndex < dd->template_cnt;
templateIndex++) {
Expand Down Expand Up @@ -265,8 +263,6 @@ static int template_dependency_structure(struct dd *dd, struct getbit *gb)

static int extended_descriptor_fields(struct dd *dd, struct getbit *gb)
{
re_printf("extended_descriptor_fields\n");

if (getbit_get_left(gb) < 5)
return EBADMSG;

Expand Down Expand Up @@ -328,11 +324,6 @@ int dd_decode(struct dd *dd, const uint8_t *buf, size_t sz)
no_extended_descriptor_fields(dd);
}

#if 0
frame_dependency_definition();
zero_padding = f(sz * 8 - TotalConsumedBits);
#endif

return 0;
}

Expand Down
13 changes: 0 additions & 13 deletions src/dd/dd_enc.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,6 @@ static int template_layers(struct putbit *pb, const struct dd *dd)

static int template_dtis(struct putbit *pb, const struct dd *dd)
{
re_printf("template_dtis\n");

for (uint8_t templateIndex = 0;
templateIndex < dd->template_cnt;
templateIndex++) {
Expand All @@ -100,8 +98,6 @@ static int template_fdiffs(struct putbit *pb, const struct dd *dd)
{
int err;

re_printf("template_fdiffs (encode) bit_pos=%zu\n", pb->bit_pos);

for (uint8_t templateIndex = 0;
templateIndex < dd->template_cnt;
templateIndex++) {
Expand Down Expand Up @@ -136,8 +132,6 @@ static int template_fdiffs(struct putbit *pb, const struct dd *dd)

static int template_chains(struct putbit *pb, const struct dd *dd)
{
re_printf("template_chains\n");

int err = putbit_write_ns(pb, dd->dt_cnt + 1, dd->chain_cnt);
if (err)
return err;
Expand Down Expand Up @@ -193,8 +187,6 @@ static int template_dependency_structure(struct putbit *pb,
{
int err;

re_printf("template_dependency_structure\n");

uint8_t dt_cnt_minus_one = dd->dt_cnt - 1;

err = putbit_write(pb, 6, dd->template_id_offset);
Expand All @@ -218,9 +210,6 @@ static int template_dependency_structure(struct putbit *pb,
if (err)
return err;

re_printf("resolutions_present_flag: %d\n",
dd->resolutions_present_flag);

err = putbit_one(pb, dd->resolutions_present_flag);
if (err)
return err;
Expand All @@ -239,8 +228,6 @@ static int extended_descriptor_fields(struct putbit *pb, const struct dd *dd)
{
int err = 0;

re_printf("extended_descriptor_fields\n");

err |= putbit_one(pb, dd->template_dependency_structure_present_flag);
err |= putbit_one(pb, dd->active_decode_targets_present_flag);
err |= putbit_one(pb, dd->custom_dtis_flag);
Expand Down
8 changes: 0 additions & 8 deletions test/dd.c
Original file line number Diff line number Diff line change
Expand Up @@ -233,8 +233,6 @@ static int test_dd_decode(void)

ASSERT_EQ(1, dd.chain_cnt);

printf("encode.\n");

err = dd_encode(mb, &dd);
TEST_ERR(err);

Expand All @@ -256,8 +254,6 @@ static int test_dd_chrome(void)
uint8_t buf[12];
int err;

printf("chrome\n");

if (!mb)
return ENOMEM;

Expand Down Expand Up @@ -306,14 +302,10 @@ static int test_dd_chrome(void)

ASSERT_EQ(0, dd.chain_cnt);

#if 1
printf("chrome encode.\n");

err = dd_encode(mb, &dd);
TEST_ERR(err);

TEST_MEMCMP(buf, sizeof(buf), mb->buf, mb->end);
#endif

out:
mem_deref(mb);
Expand Down

0 comments on commit 2f73e19

Please sign in to comment.