mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-02-06 22:54:26 +01:00
Tweak EALayer3 comment
This commit is contained in:
parent
73e60d64b1
commit
f6b4df6680
@ -789,6 +789,11 @@ fail:
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//TODO: this causes lots of rebuffering/slowness in multichannel since each stream has to read back
|
||||||
|
// (frames are interleaved like s0_g0, s1_g0, s2_g0, s0_g1, s1_g1, s2_g1, ...,
|
||||||
|
// stream0 advances buffers to s0_g1, but stream1 needs to read back to s1_g0, often trashing custom IO)
|
||||||
|
// would need to store granule0 after reading but not decoding until next?
|
||||||
|
|
||||||
/* Skip EA-frames from other streams for .sns/sps multichannel (interleaved 1 EA-frame per stream).
|
/* Skip EA-frames from other streams for .sns/sps multichannel (interleaved 1 EA-frame per stream).
|
||||||
* Due to EALayer3 being in blocks and other complexities (we can't go past a block) all
|
* Due to EALayer3 being in blocks and other complexities (we can't go past a block) all
|
||||||
* streams's offsets should start in the first stream's EA-frame.
|
* streams's offsets should start in the first stream's EA-frame.
|
||||||
|
@ -40,7 +40,7 @@ static size_t eaac_io_read(STREAMFILE *streamfile, uint8_t *dest, off_t offset,
|
|||||||
/* previous offset: re-start as we can't map logical<>physical offsets
|
/* previous offset: re-start as we can't map logical<>physical offsets
|
||||||
* (kinda slow as it trashes buffers, but shouldn't happen often) */
|
* (kinda slow as it trashes buffers, but shouldn't happen often) */
|
||||||
if (offset < data->logical_offset) {
|
if (offset < data->logical_offset) {
|
||||||
//;VGM_LOG("IO restart: offset=%lx + %x, po=%lx, lo=%lx\n", offset, length, data->physical_offset, data->logical_offset);
|
;VGM_LOG("IO restart: offset=%lx + %x, po=%lx, lo=%lx\n", offset, length, data->physical_offset, data->logical_offset);
|
||||||
data->physical_offset = data->stream_offset;
|
data->physical_offset = data->stream_offset;
|
||||||
data->logical_offset = 0x00;
|
data->logical_offset = 0x00;
|
||||||
data->data_size = 0;
|
data->data_size = 0;
|
||||||
@ -260,8 +260,7 @@ static STREAMFILE* setup_eaac_streamfile(STREAMFILE *sf, int version, int codec,
|
|||||||
/* setup subfile */
|
/* setup subfile */
|
||||||
new_sf = open_wrap_streamfile(sf);
|
new_sf = open_wrap_streamfile(sf);
|
||||||
new_sf = open_io_streamfile_f(new_sf, &io_data, sizeof(eaac_io_data), eaac_io_read, eaac_io_size);
|
new_sf = open_io_streamfile_f(new_sf, &io_data, sizeof(eaac_io_data), eaac_io_read, eaac_io_size);
|
||||||
if (codec == 0x03) /* EA-XMA only since logical data is bigger */
|
new_sf = open_buffer_streamfile_f(new_sf, 0); /* EA-XMA and multichannel EALayer3 benefit from this */
|
||||||
new_sf = open_buffer_streamfile_f(new_sf, 0);
|
|
||||||
return new_sf;
|
return new_sf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user