From 750faeb2a95785b5cf7452201a21867c18992cd7 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Tue, 7 Jul 2020 13:32:51 +0000 Subject: [PATCH] --- Reading.md | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 Reading.md diff --git a/Reading.md b/Reading.md new file mode 100644 index 0000000..193bb94 --- /dev/null +++ b/Reading.md @@ -0,0 +1,44 @@ +Reading of optical media is for now restricted to reading of data sectors, +which is done by call `burn_read_data()` of [libburn](Libburn), +reading of audio CD sectors by call `burn_read_audio()`, +and reading of CD-TEXT from audio CD by `burn_disc_get_leadin_text()`. + +This is fully sufficient for DVD media. On CD, a sector not only may host +2048 bytes of payload but stores more information which can be accessed +by special SCSI commands. An example are Audio sectors of CD-DA discs which +store payload in all their 2352 bytes. Other sector formats are known withi +payload between that maximum and 2048. + +Data reading has several use cases in libburnia: + +Demo program +[telltoc](https://dev.lovelyhq.com/libburnia/libburn/raw/HEAD/test/telltoc.c) +is able to read CD TAO tracks up to the last data sectors which are normally +inaccessible through the Linux block devices. This is due to the fact +that a TAO track announces a size which includes two non-data sectors +at the end of the track. Some drives correct this, some do not. Whether a track +was recorded by TAO is hardly to tell. In a SAO track, all announced sectors +are data sectors. telltoc solves this dilemma by reading the end sectors +of a track one-by-one. + +Application program [cdrskin](Cdrskin) emulates ISO multi-session on DVD+RW +by reading the first 64 kB of the ISO 9660 image from media, patching some +address fields and writing them back. +(Learned from Andy Polyakov's `growisofs`.) +Further, `cdrskin` is able to copy audio tracks and CD-TEXT from CD to +hard disk. + +Library [libisoburn](Libisoburn) creates an interface object for library +[libisofs](Libisofs) which can read data blocks from libburn drives. +This is used for detecting an ISO 9660 image and for loading its +directory tree and management data. `libisoburn` itself performs the same +patching of DVD+RW and similar media as can be done by `cdrskin`. + +Application program [xorriso](Xorriso) uses data reading capabilities for +comparing the content of disk files with the content of ISO image files +and for copying files from ISO image to disk. + +On several Linux systems, the block device driver needs reloading of thei +drive tray in order to make available freshly written data via its +buffered i/o. The libburn read function does not need such a reload. +