return ret;
}
-static void tunetable(long unsigned num_chunks)
-{
- int i = 1, j = -1, lp = 1;
- while (i < num_chunks) {
- if (chunk_table[i] == chunk_table[lp]) {
- i++;
- continue;
- }
- if (j < 0)
- tv_scale(i, &af->chunk_tv, &af->eof_tv);
- for (j = lp; j < i; j++)
- chunk_table[j] = chunk_table[i];
- lp = i;
- }
-#if 1
- for (i = 2; i < num_chunks; i++)
- if (chunk_table[i] != chunk_table[1])
- break;
- lp = i;
- for (i = 2; i < num_chunks - lp; i++)
- chunk_table[i] = chunk_table[i + lp];
-#endif
-}
-
-
/*
* Alloc and fill array table of byte offsets. chunk_table[i] is the
* offset in the current input file at which the sample containing time i *
}
num_chunks = i - 1;
chunk_table[i] = pos;
-// tunetable(num_chunks);
PARA_INFO_LOG("%lu chunks (%fs), max chunk: %zd, min chunk: %zd\n",
num_chunks, chunk_time, max_chunk_len, min);
return num_chunks;