StarBurn SDK (Software Development Kit)
ContentsIndexHome
PreviousUpNext
StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormatsEx Function
C++
__stdcall STARBURN_IMPEX_API VOID StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormatsEx(IN PVOID p__PVOID__CdvdBurnerGrabber, OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRWRead, OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRRead, OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRWWrite, OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRWrite);
Parameters 
Description 
IN PVOID p__PVOID__CdvdBurnerGrabber 
Pointer to the CdvdBurnerGrabber object that toolkit allocated before with the call to StarBurn_CdvdBurnerGrabber_Create().
 
OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRWRead 
Pointer to the boolean variable that will receive is device capable of reading DVD+RW discs or not.
 
OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRRead 
Pointer to the boolean variable that will receive is device capable of reading DVD+R discs or not.
 
OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRWWrite 
Pointer to the boolean variable that will receive is device capable of writing DVD+RW discs or not.
 
OUT PBOOLEAN p__PBOOLEAN__IsDVDPLUSRWrite 
Pointer to the boolean variable that will receive is device capable of writing DVD+R discs or not. 

None. This function cannot fail.

This function returns DVD+R(W) burner device object extended information. This data can be used to report the capabilities of the device to the user.

Please see the TrackAtOnceFromTree and TrackAtOnceFromFile samples that will demonstrate how ISO9660 or Joliet file system image can be burn on the DVD+R(W) media and what use can be taken from CdvdBurnerGrabber device extended information.

This example allocates CdvdBurnerGrabber object, retreives device extended information and destroys the device object after it's not needed any more. 

 

// Somewhere in the data region
PVOID l__PVOID__CdvdBurnerGrabber;
EXCEPTION_NUMBER l__EXCEPTION_NUMBER;
ULONG l__ULONG__SystemError;
ULONG l__ULONG__CacheBufferSizeInUCHARs;
CHAR l__CHAR__ExceptionText[ 1024 ];
BOOLEAN l__BOOLEAN__IsDVDPLUSRWRead;
BOOLEAN l__BOOLEAN__IsDVDPLUSRRead;
BOOLEAN l__BOOLEAN__IsDVDPLUSRWWrite;
BOOLEAN l__BOOLEAN__IsDVDPLUSRWrite;
CDB_FAILURE_INFORMATION l__CDB_FAILURE_INFORMATION;

// Prepare exception text buffer
RtlZeroMemory(
    &l__CHAR__ExceptionText,
    sizeof( l__CHAR__ExceptionText )
    );

// Prepare CDB failure information
RtlZeroMemory(
    &l__CDB_FAILURE_INFORMATION,
    sizeof( l__CDB_FAILURE_INFORMATION )
    );

// Try to create CdvdBurnerGrabber on 0:0:4:0 with 32MB of cache
l__EXCEPTION_NUMBER =
StarBurn_CdvdBurnerGrabber_Create(
    &l__PVOID__CdvdBurnerGrabber,
    ( PCHAR )( &l__CHAR__ExceptionText ),
    sizeof( l__CHAR__ExceptionText ),
    &l__ULONG__SystemError,
    &l__CDB_FAILURE_INFORMATION,
    ( PCALLBACK )( StarBurn_Callback ),
    0,
    0,
    4,
    0,
    32
    );

// Check for correct reply
if (  l__EXCEPTION_NUMBER != EN_SUCCESS )
{
// Handle error here...
}

// Get CdvdBurnerGrabber device information here...

// Get CdvdBurnerGrabber device extended information
StarBurn_CdvdBurnerGrabber_GetSupportedMediaFormatsEx(
    l__PVOID__CdvdBurnerGrabber,
    &l__BOOLEAN__IsDVDPLUSRWRead,
    &l__BOOLEAN__IsDVDPLUSRRead,
    &l__BOOLEAN__IsDVDPLUSRWWrite,
    &l__BOOLEAN__IsDVDPLUSRWrite
    );

// Do something with CdvdBurnerGrabber device object and it's extended information here...      

// Destroy the CdvdBurnerGrabber
StarBurn_Destroy( &l__PVOID__CdvdBurnerGrabber );

// Just check for pointer (paranoid?)
if ( l__PVOID__CdvdBurnerGrabber != NULL )
{
// Handle error here...
}