Public Slots | |
| void | seek () |
| void | start_io () |
| void | stop_io () |
Signals | |
| void | seekFinished () |
| void | readSourceBufferUnderRun () |
| void | writeSourceBufferOverRun () |
Public Member Functions | |
| DiskIO (Sheet *sheet) | |
| void | prepare_for_seek () |
| void | output_rate_changed (int rate) |
| void | register_read_source (ReadSource *source) |
| void | register_write_source (WriteSource *source) |
| void | set_resample_quality (int quality) |
| void | unregister_read_source (ReadSource *source) |
| void | unregister_write_source (WriteSource *source) |
| trav_time_t | get_cpu_time () |
| int | get_write_buffers_fill_status () |
| int | get_read_buffers_fill_status () |
| int | get_output_rate () |
| int | get_resample_quality () |
| DecodeBuffer * | get_resample_decode_buffer () |
Static Public Attributes | |
| static const int | writebuffertime = 5 |
| static const int | bufferdividefactor = 5 |
Friends | |
| class | DiskIOThread |
Each Sheet class has it's own DiskIO instance. The DiskIO manages all the AudioSources related to a Sheet, and makes sure the RingBuffers from the AudioSources are processed in time. (It at least tries very hard)
| void DiskIO::prepare_for_seek | ( | ) |
Interupts any pending AudioSource's buffer processing, and returns from do_work(). Use this before calling seek() to shorten the seek process.
| void DiskIO::register_read_source | ( | ReadSource * | source | ) |
Registers the ReadSource source. The source's RingBuffer will be initialized at this point.
Note: This function is thread save.
| source | The ReadSource to register |
References AudioSource::get_channel_count(), and ReadSource::set_diskio().
| void DiskIO::register_write_source | ( | WriteSource * | source | ) |
Registers the WriteSource source. The source's RingBuffer will be initialized at this point.
Note: This function is thread save.
| source | The WriteSource to register |
References WriteSource::set_diskio().
| void DiskIO::unregister_read_source | ( | ReadSource * | source | ) |
Unregisters the ReadSource from this DiskIO instance
Note: This function is Thread save.
| source | The ReadSource to be removed from the DiskIO instance. |
| trav_time_t DiskIO::get_cpu_time | ( | ) |
References RingBuffer::read(), and RingBuffer::read_space().
| int DiskIO::get_write_buffers_fill_status | ( | ) |
Get the status of the writebuffers.
References AudioDevice::get_sample_rate().
| int DiskIO::get_read_buffers_fill_status | ( | ) |
Get the status of the readbuffers.
| void DiskIO::seek | ( | ) | [slot] |
Seek's all the ReadSources readbuffers to the new position. Call prepare_seek() first, to interupt do_work() if it was running.
| position | The position to seek too |
References Sheet::get_new_transport_location(), ReadSource::rb_seek_to_file_position(), and ReadSource::set_diskio().
1.5.5