Re: burning cd with cocoa
Re: burning cd with cocoa
- Subject: Re: burning cd with cocoa
- From: Michael Scheel <email@hidden>
- Date: Sat, 9 Feb 2002 23:27:10 -0800
(I hope I'm replying to this correctly, as I get the digest and I'm not sure :)
Not sure if this will help you, but you could look at the command-line
tool /usr/bin/hdiutil. (either find the source, not sure if you can, or
call it from your program). It supports creating a disk image, mounting
it (so that you can write stuff to it) and then burning it, as this example
from the man page describes:
Image from folder:
$ du -s myFolder # du(1) seems to find resource forks, even on HFS+
1234
$ hdiutil create -sectors 1334 folderImage # add 100 sectors
$ hdid -nomount folderImage.dmg
/dev/disk1s2
$ newfs_hfs -v myFolderImage /dev/rdisk1s2
$ hdiutil eject disk1
$ hdid folderImage.dmg
/dev/disk1s2 Apple_HFS /Volumes/myFolderImage
$ ditto -rsrcFork myFolder /Volumes/myFolderImage
then after ejecting that again, something like
hdiutil burn folderImage.dmg
Automating this programmatically may be tricky, but perhaps it will get
you started. I've had success with this, and with cdrtools/cdrecord
(available via fink (though currently unstable); better diagnostic and
other informational output, imo)
I also cheat and use this to eject disks instead of dragging them to the
trash :) It even has builtin support for getting administrator access.
(If this is too "unix" an answer, I apologize, and am willing to answer
any questions via email.)
Good luck,
Michael Scheel
On Thu, Feb 07, 2002 at 09:55:09PM -0800, email@hidden wrote:
>
Subject: burning cd with cocoa
>
From: Philipp Seibel <email@hidden>
>
>
Is it possible to burn discs with cocoa? I4d like to implement burning
>
support like iTunes, perhaps anyone knows how to do it. (I know iTunes
>
is Carbon, but perhaps there is a possibility with cocoa
--
| Michael Scheel |Network Under Construction Ahead
| UNIX Chaperone |Left Bit Closed
| E Pluribus UNIX |Shift Right
| www.osxtreme.net email@hidden
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.