I'm needing to read raw data from an ISO 9660 (Audio) CD ROM in both Unix and Windows! I've got my structures all ready (I hope) but filling them is proving to be troublesome (especially in Windows).
I'm needing to read raw data from an ISO 9660 (Audio) CD ROM in both Unix and Windows! I've got my structures all ready (I hope) but filling them is proving to be troublesome (especially in Windows).
What specifically is the problem? What do you mean you are having trouble "filling your structures"? Post some code so we can see what you're trying to do.
This will be platform specific, so you'll need to duplicate some code to account for the Windows and Unix-specific parts. Here are some knowledgebase articles from MSDN that should help for Windows:
I think Unix will be a lot more straightforward. You can probably just open and read the "raw" device using the regular POSIX functions (open, read, close). So if your cd-rom is mounted on /dev/cd0, you'll want to access the raw device, which might be /dev/rcd0. The device names will differ across Unices.
You may want to abstract the platform-specific stuff into a class so that code that wants to work with the cd roms doesn't have to know which platform its running on.
class iso_9660_sector {
// components of a single sector
};
class iso_9660 {
public:
iso_9660 &open_device(std::string device_name);
iso_9660 &close_device();
iso_9660_sector read_sector();
// etc.
};
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.