Karthik V

I'm unable to burn DVDs with the same code that burns a few photos to CDs. After the writing completes, the files seem to be corrupt. Investigated a bit, and these are my observations:

1) I tried doing this with the imapi2sample C++ that is under \winbase\imapi2. This works fine. Writing the DVD with some software like Deepburner works fine too.

2) Tried burning the same files with the C# sample IBurn.exe that is under \winbase\storage. This runs to the end. After completion, the DVD contained those files I burnt, but I couldn't open any of those (corrupt files). Note that this sample comes with a .NET interop file and the application uses this interop.

When I burn using my code (that successfully burns CDs), I couldn't even open the DVD - I got an error like "corrupt file system" or something. I'm assuming that this problem isn't completely to do with my code because the sample didn't work too.

My drive is Plextor PX-716A. Media is DVD-R (tried DVD+R too). I'm using the latest Vista SDK.

Please let me know what could go wrong in writing DVDs with the .NET interop. Is there a problem using the same code for CDs and DVDs

Re: Optical Platform Discussion DVD burning Vs CD burning?

Henry Gabryjelski - MSFT

Hi Karthik,

I admit that I have little experience with the interop code.

Using the same code for CD/DVD media should work just fine. I am not aware of any particular issues with the interop code. One relatively easy way to debug the interop code would be to run both and compare the resulting .ISO files (either take the IStream and dump it to a file, or dump the disc images to file). Both should be identical.

What could go wrong The IO.Stream <--> IStream conversion might not be correct. Perhaps another reader on this forum with experience in this area could help out


Re: Optical Platform Discussion DVD burning Vs CD burning?

Karthik V

Thanks for the reply. Unfortunately, it has been a while since I posted the question and I've stopped working on it now. Will keep your tip in mind if I happen to work on IMAPI2 again.