PrimoBurner for .NET  5.0
CD, DVD and Blu-ray Software Development Kit
Loading...
Searching...
No Matches
Device Class Reference

Recording Device Low Level Application Programming Interface. More...

Inherits IDisposable.

Public Member Functions

void ClearOutputBuffer ()
 Clears the buffer that is used for writing.
 
bool CloseDisc ()
 Closes an open BD-R disc.
 
bool CloseLastSession ()
 Closes the last open session on the disc.
 
bool CloseTrack (Int32 trackNumber)
 Closes a track.
 
TrackType DetectTrackType (Int32 trackStartLba)
 Returns the type of a CD track.
 
TrackType DetectTrackType (Int32 trackStartLba, Int32 blocksToScan)
 Returns the type of a CD track.
 
bool DisableMCN ()
 Disables media change notifications.
 
bool Dismount ()
 Tries to dismount the volume in the device.
 
void Dispose ()
 Disposes Device and reclaims the resources used by the object.
 
bool Eject (bool eject)
 Ejects the media from the device.
 
bool Eject (bool eject, bool unlockMedium)
 Ejects the media from the device.
 
bool EnableMCN ()
 Enables media change notifications.
 
bool EndBDSession ()
 The EndBDSession method finishes a BD session that has been previously started with the StartBDSession method.
 
bool EndBDSession (bool closeSession, bool closeDisc)
 The EndBDSession method finishes a BD session that has been previously started with the StartBDSession method.
 
bool EndBDTrack ()
 The EndBDTrack closes a BD track.
 
bool EndBDTrack (bool closeTrack)
 The EndBDTrack completes a BD track.
 
bool EndCDSession ()
 Finishes a CD session which has been previously started with the StartCDSession method.
 
bool EndCDTrack ()
 Ends a CD track.
 
bool EndCDTrack (bool closeTrack)
 Ends a CD track.
 
bool EndDVDSession ()
 Finishes a DVD session that has been previously started with the StartDVDSession method.
 
bool EndDVDSession (bool closeSession)
 Finishes a DVD session that has been previously started with the StartDVDSession method.
 
bool EndDVDTrack ()
 The EndDVDTrack completes a DVD fragment (track).
 
bool EndDVDTrack (bool closeTrack)
 The EndDVDTrack completes a DVD fragment (track).
 
bool Erase ()
 Attempts to perform a quick erase of a CD-RW or DVD-RW media if the device supports RW media.
 
bool Erase (bool quick)
 Attempts to erase a CD-RW or DVD-RW media if the device supports RW media.
 
bool Erase (EraseType type)
 Attempts to erase a CD-RW or DVD-RW media if the device supports RW media.
 
bool Flush ()
 Flushes the device internal cache buffer.
 
bool Format (FormatType type)
 Formats a re-writable DVD media.
 
bool Format (FormatType type, Int32 blocks)
 Formats a re-writable DVD media.
 
bool Format (FormatType type, Int32 blocks, bool waitForBackground)
 Formats a re-writable DVD media.
 
bool FormatBD (BDFormatType type, BDFormatSubType subType)
 Formats BD-R SRM or BD-RE media.
 
bool FormatBD (BDFormatType type, BDFormatSubType subType, BDFormatParameters formatParameters)
 Formats BD-R SRM or BD-RE media.
 
QSubChannel GetQSubChannel (SubChannelFormat channelFormat, byte[] rawCdData)
 Returns the Q Sub-channel data from a raw audio cd block.
 
ScsiInterface GetScsiInterface ()
 Creates and returns a new ScsiInterface object which can be used to send SCSI commands to the underlying hardware device.
 
IList< PrimoSoftware.Burner.SpeedDescriptorGetWriteSpeeds ()
 Reads the burning speeds supported by the device into a IList collection of SpeedDescriptor objects.
 
bool LockMedia (bool lockMedia)
 Enables or disables manual removal of the medium in the device.
 
bool LockOutputBuffer (Int32 blocks, out Int64 buffer1, out Int32 bufferBlocks1, out Int64 buffer2, out Int32 bufferBlocks2)
 Obtains a buffer for storing user data that will be written to the device.
 
bool LockOutputBuffer (Int32 blocks, out Int64 buffer1, out Int32 bufferBlocks1, out Int64 buffer2, out Int32 bufferBlocks2, out Int32 blockSize)
 Obtains a buffer for storing user data that will be written to the device.
 
bool RawCDRead (Int32 startLba, SubChannelFormat channelFormat, Int32 blockSize, byte[]buffer, Int32 numberOfBlocksToRead, ref Int32 numberOfBlocksRead)
 Reads raw data from a CD.
 
bool ReadAudio (TrackBuffer trackBuffer, Int32 startAddress)
 The readAudio method reads digital audio data from the media.
 
bool ReadAudio (TrackBuffer trackBuffer, Int32 startAddress, Int32 blocks)
 The readAudio method reads digital audio data from the media.
 
CDSession ReadCDSessionLayout (byte sessionNumber)
 Extracts a CDSession object from a CD session.
 
CDSession ReadCDSessionLayout (byte sessionNumber, bool performIndexScan)
 Extracts a CDSession object from a CD session.
 
CDSession ReadCDSessionLayout (byte sessionNumber, bool performIndexScan, bool fastScan, Int32 fastScanBlocks)
 Extracts a CDSession object from a CD session.
 
CDText ReadCDText ()
 Reads the CD-TEXT of Audio CD.
 
bool ReadData (TrackBuffer trackBuffer, Int32 startAddress)
 Reads data from the media.
 
bool ReadData (TrackBuffer trackBuffer, Int32 startAddress, Int32 blocks)
 Reads data from the media.
 
DiscInfo ReadDiscInfo ()
 Reads information about the disk.
 
MediaInfo ReadMediaInfo ()
 Retrieves extended information from the media in the device.
 
RawToc ReadRawToc ()
 Reads the Full Table-Of-Content in raw format.
 
SessionInfo ReadSessionInfo ()
 Returns information about the disc sessions.
 
Toc ReadToc ()
 Reads the Table-Of-Content of a CD.
 
Toc ReadTocFromSession (byte sessionNumber)
 Reads the Table-Of-Content of a session.
 
TrackInfoEx ReadTrackInfoEx (Int32 trackNumber)
 Returns extended information about a track.
 
void Refresh ()
 The Refresh method re-reads disc information.
 
bool ReserveTrack (Int32 blocks)
 Reserves a track.
 
bool ReserveTrackLBA (Int32 endLBA)
 Reserves a track by specifying the end logical block address instead of size.
 
bool Reset ()
 The Reset method resets the device firmware.
 
bool SetCDText (CDText cdText)
 Sets the CD-TEXT data that should be written to the CD.
 
bool StartBDSession ()
 The StartBDSession method initializes a new Blu-ray Disc session.
 
bool StartBDTrack (Int32 blocks)
 The StartBDTrack method starts a new track or continues and existing track from a BD session.
 
bool StartCDSession (bool simulate, CDSession session)
 Starts the recording of a new CD session.
 
bool StartCDSession (bool simulate, CDSession session, WriteMethod wm)
 Starts the recording of a new CD session.
 
bool StartCDSession (bool simulate, CDSession session, WriteMethod wm, bool closeSession, bool closeDisc)
 Starts the recording of a new CD session.
 
bool StartCDTrack (CDTrack newTrack)
 Starts a new track on a TAO or Packet session.
 
bool StartDVDSession (bool simulate)
 Initializes a new DVD session.
 
bool StartDVDSession (bool simulate, WriteMethod writeMethod)
 Initializes a new DVD session.
 
bool StartDVDSession (bool simulate, WriteMethod writeMethod, bool closeDisc)
 Initializes a new DVD session.
 
bool StartDVDTrack (Int32 blocks)
 Starts a new track or continues an existing track from a DVD session.
 
void UnlockOutputBuffer (Int32 blocks)
 Unlocks the write buffer and writes the data from the buffer to the disc.
 
void UnlockOutputBufferEx (Int32 blocks, Int32 discAddress)
 Unlocks the write buffer and writes the data from the buffer to the disc.
 
bool WriteData (Int32 startLba, byte[] buffer, Int32 blocks, Int32 blockSize)
 The WriteData method writes data to a CD, DVD or BD starting at the logical block address indicated by the startLba parameter.
 

Properties

BDFeatures BDFeatures [get]
 Returns a BDFeatures object describing the Blu-ray Disc capabilities of the device.
 
bool BDWriteVerify [get, set]
 Indicates whether the device should do automatic verify-after-write cycle while writing data to BD media.
 
double BgFormatProgress [get]
 Gets the background format progress as a percentage.
 
BgFormatStatus BgFormatStatus [get]
 Gets the background format status of the mounted disc.
 
CDFeatures CDFeatures [get]
 Returns a CDFeatures object describing the CD capabilities of the device.
 
string Description [get]
 Gets the device description as it is set by its manufacturer.
 
char DriveLetter [get]
 Gets the device drive letter.
 
DVDFeatures DVDFeatures [get]
 Returns a DVDFeatures object describing the DVD capabilities of the device.
 
bool DVDWriteVerify [get, set]
 Indicates whether the device should do automatic verify-after-write cycle while writing data to DVD media.
 
double EraseProgress [get]
 Gets/sets a percentage showing the progress of an erase operation started with the Device.Erase method.
 
ErrorInfo Error [get]
 Returns information about the last error that occurred while using the Device object.
 
double FormatProgress [get]
 Gets/sets a percentage showing the progress of a format operation started with the Device.Format method.
 
IntPtr Handle [get]
 Gets the operating system device handle.
 
Int32 InternalCacheCapacity [get]
 Gets the capacity of the device internal cache buffer.
 
Int32 InternalCacheUsedSpace [get]
 Gets the number of bytes used in the device internal cache.
 
Int32 MaxReadSpeedKB [get]
 Gets the maximum supported read speed in Kbytes/s.
 
Int32 MaxWriteSpeedKB [get]
 Gets the maximum supported write speed in Kbytes/s.
 
Int64 MediaCapacity [get]
 Gets the block capacity of the media inserted in the device.
 
Int64 MediaFreeSpace [get]
 Gets the numbers of blocks that can be added to the disc in the device before an additional add will cause a failure for lack of space.
 
bool MediaIsBD [get]
 Indicates whether the media in the device is BD-R or BD-RE.
 
bool MediaIsBlank [get]
 Indicates that the media in the device is blank.
 
bool MediaIsCD [get]
 Indicates whether the media in the device is CD-ROM, CD-R or CD-RW.
 
bool MediaIsDVD [get]
 Indicates whether the medium in the device is DVD-ROM, DVD-RAM, DVD-R/RW or DVD+R/RW.
 
bool MediaIsFormatted [get]
 Indicates whether the media in the device is formatted.
 
bool MediaIsReWritable [get]
 Indicates whether the media in the device is re-writable.
 
Int64 MediaLayerCapacity [get]
 Returns the layer 0 (L0) capacity, in blocks, of DVD-R DL and DVD+R DL media.
 
MediaProfile MediaProfile [get]
 Gets the type of the media that is currently inserted in the device.
 
MediaReady MediaState [get]
 Indicates whether there is medium inserted in the device.
 
Int32 NewSessionStartAddress [get, set]
 Gets/Sets the start address of the new disc session.
 
Int32 NewTrackStartAddress [get]
 Gets the start address of the next disc track.
 
string ProductId [get]
 Gets the product id (the model) of the device as it is set by its manufacturer.
 
Int32 ReadSpeedKB [get, set]
 Gets/Sets the read speed in Kbytes/s.
 
string Revision [get]
 Gets the revision (the version) of the device's firmware as it is set by its manufacturer.
 
string ScsiAddress [get]
 Gets the SCSI bus address of the device as string in the form of (Host Adapter Number:Target ID:LUN)
 
bool Streaming [get, set]
 Indicates whether the device should use stream recording or not.
 
String SystemPath [get]
 Returns the system path that identifies the device.
 
Int32 UnitReady [get]
 Indicates whether the device is ready.
 
string Vendor [get]
 Gets the device vendor name as set by the manufacturer.
 
string VendorSpecificInfo [get]
 Gets the vendor specific information of the device as it is set by its manufacturer.
 
Int32 WriteSpeedKB [get, set]
 Gets/Sets the write speed in Kbytes/s.
 
Int32 WriteTransferRate [get]
 Gets the actual write transfer rate (write speed) as measured by PrimoBurner.
 

Events

EventHandler< DeviceContinueEventArgsOnContinueRead
 Raised to check if a long read operation should continue.
 
EventHandler< DeviceEraseEventArgsOnErase
 Raised to report the progress of a disc blanking operation started with the Erase method.
 
EventHandler< DeviceFormatEventArgsOnFormat
 Raised to report the progress of a format operation started with the Format method.
 
EventHandler< DeviceReadEventArgsOnRead
 Raised to report the progress of long read operations.
 
EventHandler< DeviceWriteLeadInEventArgsOnWriteLeadIn
 Raised to report the progress during the recording of the lead-in area of a CD session.
 
EventHandler< DeviceWriteLeadOutEventArgsOnWriteLeadOut
 Raised to report the progress during the recording of the lead-out area of a CD session when RAW CD writng is used.
 

Detailed Description

Recording Device Low Level Application Programming Interface.

Member Function Documentation

◆ ClearOutputBuffer()

void ClearOutputBuffer ( )

Clears the buffer that is used for writing.

The buffer is filled with zeros. This method should be called when the current burn operation is about to be canceled.

Returns
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ CloseDisc()

bool CloseDisc ( )

Closes an open BD-R disc.

Last session on the disc must be closed before this method is called.

Version
2.00
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ CloseLastSession()

bool CloseLastSession ( )

Closes the last open session on the disc.

Returns
true - The last open session was closed successfully, or the media is a blank unformatted BD-R.

false - An error occured or the media is blank unformatted BD-RE.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ CloseTrack()

bool CloseTrack ( Int32  trackNumber)

Closes a track.

Parameters
trackNumberTrack to be closed. The track number is 1 based. To close the last track pass 0 for trackNumber.
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ DetectTrackType() [1/2]

TrackType DetectTrackType ( Int32  trackStartLba)

Returns the type of a CD track.

To detect the track type the method actually scans several blocks from the disc that is in the device. This method requires a valid recorded disc to be present in the device.

Parameters
trackStartLbaLogical block address of the track start.

NOTES:

1) To detect the track type the method reads blocksToScan blocks starting from trackStartLba.

2)A valid recorded disc must be present in the device.

Returns
A TrackType value
See also
TrackType
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.DetectTrackType().

Referenced by Device.DetectTrackType().

◆ DetectTrackType() [2/2]

TrackType DetectTrackType ( Int32  trackStartLba,
Int32  blocksToScan 
)

Returns the type of a CD track.

To detect the track type the method actually scans several blocks from the disc that is in the device. This method requires a valid recorded disc to be present in the device.

Parameters
trackStartLbaLogical block address of the track start.
blocksToScanNumber of blocks to scan (read) from the disc. This parameter has a default value of 10.

NOTES:

1) To detect the track type the method reads blocksToScan blocks starting from trackStartLba.

2)A valid recorded disc must be present in the device.

Returns
A TrackType value
See also
TrackType
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ DisableMCN()

bool DisableMCN ( )

Disables media change notifications.

This prevents Windows from sending the IO MEDIA ARRIVAL and IO MEDIA REMOVAL events to applications. This method works only on Windows XP and above.

Version
2.20
Returns
true - Success.

false - Failure.

See also
EnableMCN
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Dismount()

bool Dismount ( )

Tries to dismount the volume in the device.

That forces the operating system to invalidate its cache and to refresh the file system information.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Eject() [1/2]

bool Eject ( bool  eject)

Ejects the media from the device.

Parameters
ejectIndicates whether to eject the tray of device. If this parameter is true, the media is ejected. If this parameter is false the device tray is closed.
Version
2.06
Returns
true - Success. It is unknown whether the tray actually ejected.

false - The device does not support the eject command.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.Eject().

Referenced by Device.Eject().

◆ Eject() [2/2]

bool Eject ( bool  eject,
bool  unlockMedium 
)

Ejects the media from the device.

Parameters
ejectIndicates whether to eject the tray of device. If this parameter is true, the media is ejected. If this parameter is false the device tray is closed.
unlockMediumIndicates that the medium must be ejected even if the device tray is locked.
Version
2.06
Returns
true - Success. It is unknown whether the tray actually ejected.

false - The device does not support the eject command.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EnableMCN()

bool EnableMCN ( )

Enables media change notifications.

This method works only on Windows XP and above.

Version
2.20
Returns
true - Success.

false - Failure.

See also
DisableMCN
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EndBDSession() [1/2]

bool EndBDSession ( )

The EndBDSession method finishes a BD session that has been previously started with the StartBDSession method.

This method leaves the disc open.

The session is closed and so is the disc

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.EndBDSession().

Referenced by Device.EndBDSession().

◆ EndBDSession() [2/2]

bool EndBDSession ( bool  closeSession,
bool  closeDisc 
)

The EndBDSession method finishes a BD session that has been previously started with the StartBDSession method.

This method leaves the disc open.

Parameters
closeSessionIndicates that the session should be closed. This parameter is ignored if closeDisc is set to "true". The default value of this parameter is "true".
closeDiscIndicates that the disc should be closed. The default value of this parameter is "true".
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EndBDTrack() [1/2]

bool EndBDTrack ( )

The EndBDTrack closes a BD track.

Track is closed.

This parameter must be set to true if the EndBDSession method will be called with closeSession or closeDisc parameters set to true.

Version
2.00
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.EndBDTrack().

Referenced by Device.EndBDTrack().

◆ EndBDTrack() [2/2]

bool EndBDTrack ( bool  closeTrack)

The EndBDTrack completes a BD track.

Parameters
closeTrackIndicates whether the track should be closed. The default value of this parameter is "true".

This parameter must be set to true if the EndBDSession method will be called with closeSession or closeDisc parameters set to true.

Version
2.00
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EndCDSession()

bool EndCDSession ( )

Finishes a CD session which has been previously started with the StartCDSession method.

Version
1.20
Returns
true - Success.

false - Failure.

See also
StartCDSession
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EndCDTrack() [1/2]

bool EndCDTrack ( )

Ends a CD track.

The track will also be closed.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.EndCDTrack().

Referenced by Device.EndCDTrack().

◆ EndCDTrack() [2/2]

bool EndCDTrack ( bool  closeTrack)

Ends a CD track.

Parameters
closeTrackIndicates that the track should be closed.
This parameter must be set to true if a write method different than WriteMethod.Packet is used.
In Packet mode the track can be left open to allow recording of data at the end of the track at a later time.
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EndDVDSession() [1/2]

bool EndDVDSession ( )

Finishes a DVD session that has been previously started with the StartDVDSession method.

The session will be closed.

Returns
true - Success.

false - Failure.

See also
Device.StartDVDSession
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.EndDVDSession().

Referenced by Device.EndDVDSession().

◆ EndDVDSession() [2/2]

bool EndDVDSession ( bool  closeSession)

Finishes a DVD session that has been previously started with the StartDVDSession method.

Parameters
closeSessionIndicates that the session should be closed. The default value of this parameter is "true".

The session is always closed when Disc-At-Once recording is performed regardless of the value of the 'closeSession' parameter.

Returns
true - Success.

false - Failure.

See also
Device.StartDVDSession
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EndDVDTrack() [1/2]

bool EndDVDTrack ( )

The EndDVDTrack completes a DVD fragment (track).

The track will be closed.

If the Incremental (WriteMethod.DvdIncremental) method is used the application may leave the track open to allow recording of data at the end of the track at a later time by setting this parameter value to false.

This parameter must be set to true if the Disc-At-Once (WriteMethod.DvdDao) write method is used.

This parameter must be set to true if the StartDVDSession method was previously called with the 'closeDisc' parameter set to true.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.EndDVDTrack().

Referenced by Device.EndDVDTrack().

◆ EndDVDTrack() [2/2]

bool EndDVDTrack ( bool  closeTrack)

The EndDVDTrack completes a DVD fragment (track).

Parameters
closeTrackIndicates whether the track should be closed. The default value of this parameter is "true".

If the Incremental (WriteMethod.DvdIncremental) method is used the application may leave the track open to allow recording of data at the end of the track at a later time by setting this parameter value to false.

This parameter must be set to true if the Disc-At-Once (WriteMethod.DvdDao) write method is used.

This parameter must be set to true if the StartDVDSession method was previously called with the 'closeDisc' parameter set to true.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Erase() [1/3]

bool Erase ( )

Attempts to perform a quick erase of a CD-RW or DVD-RW media if the device supports RW media.

Returns
true - The media in the recorder has been erased successfully.

false - The erasing failed.

See also
Device.MediaIsReWritable
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.Erase().

Referenced by Device.Erase().

◆ Erase() [2/3]

bool Erase ( bool  quick)

Attempts to erase a CD-RW or DVD-RW media if the device supports RW media.

Parameters
quickIndicates the erase type. If this parameter is true, a quick erase is performed. If this parameter is false, a full erase is performed. The default value of this parameter is "true".
Returns
true - The media in the recorder has been erased successfully.

false - The erasing failed.

See also
Device.MediaIsReWritable
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Erase() [3/3]

bool Erase ( EraseType  type)

Attempts to erase a CD-RW or DVD-RW media if the device supports RW media.

Parameters
typeIndicates the erase type.
Returns
true - The media in the recorder has been erased successfully.

false - The erasing failed.

See also
EraseType, Device.MediaIsReWritable
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Flush()

bool Flush ( )

Flushes the device internal cache buffer.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Format() [1/3]

bool Format ( FormatType  type)

Formats a re-writable DVD media.

Depending on the media profile different formatting can be performed.

Parameters
typeType of the format that should be performed.

See the FormatType enumeration for details about all the format types. See the MediaProfile enumeration for details about all media types.

DVD+RW – the format has two phases - "foreground" and "background". The foreground format is very short and is executed synchronously. After the foreground format is completed the background format continues until the whole DVD+RW disc is fully formatted. During the background format the DVD/CD writing is possible on the part of the disc that has been formatted.

DVD-RW – when used with FormatType.DvdMinusRwQuick you can set blocks to 0 to make it a really quick format.

When waitForBackground is set to true the Format method will wait until the background format is completed and will use the OnFormat event to report the format progress.


Returns
true - Success.

false - Failure.

See also
PrimoSoftware.Burner.FormatType, PrimoSoftware.Burner.MediaProfile, PrimoSoftware.Burner.BgFormatStatus
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References PrimoSoftware.Burner.Format.

◆ Format() [2/3]

bool Format ( FormatType  type,
Int32  blocks 
)

Formats a re-writable DVD media.

Depending on the media profile different formatting can be performed.

Parameters
typeType of the format that should be performed.
blocksThe number of blocks(sectors) that should be formatted.
This parameter is ignored for DVD+RW media when the value of the format type is FormatType.DvdPlusRwFull, FormatType.DvdPlusRwRestart or FormatType.DvdPlusRwStop.

See the FormatType enumeration for details about all the format types. See the MediaProfile enumeration for details about all media types.

DVD+RW – the format has two phases - "foreground" and "background". The foreground format is very short and is executed synchronously. After the foreground format is completed the background format continues until the whole DVD+RW disc is fully formatted. During the background format the DVD/CD writing is possible on the part of the disc that has been formatted.

DVD-RW – when used with FormatType.DvdMinusRwQuick you can set blocks to 0 to make it a really quick format.

When waitForBackground is set to true the Format method will wait until the background format is completed and will use the OnFormat event to report the format progress.


Returns
true - Success.

false - Failure.

See also
PrimoSoftware.Burner.FormatType, PrimoSoftware.Burner.MediaProfile, PrimoSoftware.Burner.BgFormatStatus
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References PrimoSoftware.Burner.Format.

◆ Format() [3/3]

bool Format ( FormatType  type,
Int32  blocks,
bool  waitForBackground 
)

Formats a re-writable DVD media.

Depending on the media profile different formatting can be performed.

Parameters
typeType of the format that should be performed.
blocksThe number of blocks(sectors) that should be formatted.
This parameter is ignored for DVD+RW media when the value of the format type is FormatType.DvdPlusRwFull, FormatType.DvdPlusRwRestart or FormatType.DvdPlusRwStop.
waitForBackgroundUse this parameter to block in the Format method until the background format is completed. This parameter is ignored if format type is other than FormatType.DvdPlusRwFull, FormatType.DvdPlusRwRestart.

See the FormatType enumeration for details about all the format types. See the MediaProfile enumeration for details about all media types.

DVD+RW – the format has two phases - "foreground" and "background". The foreground format is very short and is executed synchronously. After the foreground format is completed the background format continues until the whole DVD+RW disc is fully formatted. During the background format the DVD/CD writing is possible on the part of the disc that has been formatted.

DVD-RW – when used with FormatType.DvdMinusRwQuick you can set blocks to 0 to make it a really quick format.

When waitForBackground is set to true the Format method will wait until the background format is completed and will use the OnFormat event to report the format progress.


Returns
true - Success.

false - Failure.

See also
PrimoSoftware.Burner.FormatType, PrimoSoftware.Burner.MediaProfile, PrimoSoftware.Burner.BgFormatStatus
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ FormatBD() [1/2]

bool FormatBD ( BDFormatType  type,
BDFormatSubType  subType 
)

Formats BD-R SRM or BD-RE media.

Depending on the media profile different formatting are available.

Parameters
typeThe type of the format that should be performed.
subTypeThe format sub type. The value of this parameter depends on the value of the type parameter.
Returns
true - Success.

false - Failure.

See also
BDFormatType, BDFormatSubType


Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.FormatBD().

Referenced by Device.FormatBD().

◆ FormatBD() [2/2]

bool FormatBD ( BDFormatType  type,
BDFormatSubType  subType,
BDFormatParameters  formatParameters 
)

Formats BD-R SRM or BD-RE media.

Depending on the media profile different formatting are available.

Parameters
typeThe type of the format that should be performed.
subTypeThe format sub type. The value of this parameter depends on the value of the type parameter.
formatParametersReserved. Must be set to null.
Returns
true - Success.

false - Failure.

See also
BDFormatType, BDFormatSubType
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ GetQSubChannel()

QSubChannel GetQSubChannel ( SubChannelFormat  channelFormat,
byte[]  rawCdData 
)

Returns the Q Sub-channel data from a raw audio cd block.

The function reads the sub-channel information from the last ChannelSize.Pw (96) bytes of the RAW CD block passed with the rawCdData parameter.

Parameters
channelFormatExpected format of the sub-channel data.
rawCdDataA buffer that contains BlockSize.CdRaw (2448) bytes of RAW CD data. Use the Device.RawCDRead method to read CD data in RAW mode.
Returns
If successful the method returns a QSubchannel with the requested sub-channel data. If the sub-channel data is invalid or missing the method returns null.
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ GetScsiInterface()

ScsiInterface GetScsiInterface ( )

Creates and returns a new ScsiInterface object which can be used to send SCSI commands to the underlying hardware device.

The ScsiInterface object needs to be disposed when not needed anymore.

Version
1.98
Returns
A ScsiInterface object or null if an error occured.
See also
PrimoSoftware.Burner.ScsiInterface
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ GetWriteSpeeds()

IList< PrimoSoftware.Burner.SpeedDescriptor > GetWriteSpeeds ( )

Reads the burning speeds supported by the device into a IList collection of SpeedDescriptor objects.

If the device is not capable of reporting multiple speed descriptors, this method reports a collection with one object in it that describes the maximum write speed. If that is the case, check the the error property for the actual reason.

Returns
Supported write speeds as a list of SpeedDescriptor objects.
See also
SpeedDescriptor
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.
ObjectDisposedExceptionThe Device object was already disposed.

◆ LockMedia()

bool LockMedia ( bool  lockMedia)

Enables or disables manual removal of the medium in the device.

Parameters
lockMediaIndicates whether the device tray mechanism can be opened /closed by the device operator. Set this parameter to true to prevent manual ejecting of the medium and to false to allow manual ejecting of the medium.
Version
1.2
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ LockOutputBuffer() [1/2]

bool LockOutputBuffer ( Int32  blocks,
out Int64  buffer1,
out Int32  bufferBlocks1,
out Int64  buffer2,
out Int32  bufferBlocks2 
)

Obtains a buffer for storing user data that will be written to the device.

Parameters
blocksSize, in blocks, of the portion of the buffer to lock. Note that the output buffer is conceptually circular.
buffer1Upon successful execution this parameter will contain the address of the first block of the output buffer to be locked.
bufferBlocks1Upon successful execution this parameter will contain the number of blocks pointed to by the buffer1 parameter. If this value is less than the blocks parameter, buffer2 will point to a second portion of the output buffer.
buffer2Upon successful execution this parameter will contain the address of the second block of the output buffer to be locked.
bufferBlocks2Upon successful execution this parameter will contain the number of blocks pointed to by the buffer2 parameter. If buffer2 is 0, this value will be 0.

The size of the blocks depends on the write method (WriteMethod) and the current session (Device.StartCDSession, Device.StartDVDSession, Device.StartBDSession).

Returns
true - Success.

false - Failed to lock buffer. This may happen when the number of blocks requested is too big.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.LockOutputBuffer().

Referenced by Device.LockOutputBuffer().

◆ LockOutputBuffer() [2/2]

bool LockOutputBuffer ( Int32  blocks,
out Int64  buffer1,
out Int32  bufferBlocks1,
out Int64  buffer2,
out Int32  bufferBlocks2,
out Int32  blockSize 
)

Obtains a buffer for storing user data that will be written to the device.

Parameters
blocksSize, in blocks, of the portion of the buffer to lock. Note that the output buffer is conceptually circular.
buffer1Upon successful execution this parameter will contain the address of the first block of the output buffer to be locked.
bufferBlocks1Upon successful execution this parameter will contain the number of blocks pointed to by the buffer1 parameter. If this value is less than the blocks parameter, buffer2 will point to a second portion of the output buffer.
buffer2Upon successful execution this parameter will contain the address of the second block of the output buffer to be locked.
bufferBlocks2Upon successful execution this parameter will contain the number of blocks pointed to by the buffer2 parameter. If buffer2 is 0, this value will be 0.
blockSizeUpon successful execution this parameter will contain the size of a single block from the locked output buffer
Returns
true - Success.

false - Failed to lock buffer. This may happen when the number of blocks requested is too big.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ RawCDRead()

bool RawCDRead ( Int32  startLba,
SubChannelFormat  channelFormat,
Int32  blockSize,
byte[]  buffer,
Int32  numberOfBlocksToRead,
ref Int32  numberOfBlocksRead 
)

Reads raw data from a CD.

Parameters
startLbaThe logical block address from which the reading should start
channelFormatThe expected format of the sub-channel data. The sub-channel data occupies the last ChannelSize.PW (96) bytes from a RAW CD block. The size of a RAW CD block is BlockSize.CdRaw (2448) bytes.
blockSizeThe size of a raw block. This parameter should be set to BlockSize.Cdda if the selected sub-channel data format is
SubChannelFormat.None and to BlockSize.CdRaw if the selected channel is set to SubChannelFormat.PWRaw or SubChannelFormat.PWDeinterleaved.
bufferBuffer that receives the data read from the disc. The size fo the buffer must be at least (blockSize * numberOfBlocksToRead) bytes.
numberOfBlocksToReadNumber of blocks to read.
numberOfBlocksReadReceives the number of blocks read. RawCDRead sets this value to zero before the reading.
Returns
true - Success.

false - Failure.

See also
SubChannelFormat
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadAudio() [1/2]

bool ReadAudio ( TrackBuffer  trackBuffer,
Int32  startAddress 
)

The readAudio method reads digital audio data from the media.

Reads up to DefaultBufferSize.Cd blocks from the medium.

Parameters
trackBufferUpon successful execution the track buffer will contain the data read from the medium. The TrackBuffer object must be created before calling this method.
startAddressAddress (in blocks) at which to start the reading operation
Version
1.10
Returns
true - Success

false - Error

See also
TrackBuffer
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.ReadAudio().

Referenced by Device.ReadAudio().

◆ ReadAudio() [2/2]

bool ReadAudio ( TrackBuffer  trackBuffer,
Int32  startAddress,
Int32  blocks 
)

The readAudio method reads digital audio data from the media.

Parameters
trackBufferUpon successful execution the track buffer will contain the data read from the medium. The TrackBuffer object must be created before calling this method.
startAddressAddress (in blocks) at which to start the reading operation
blocksNumber of blocks to be read
Version
1.10
Returns
true - Success

false - Error

See also
TrackBuffer
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References TrackBuffer.Blocks, and TrackBuffer.BlockSize.

◆ ReadCDSessionLayout() [1/3]

CDSession ReadCDSessionLayout ( byte  sessionNumber)

Extracts a CDSession object from a CD session.

Creates a CDSession object with the track and index information of the extracted session (also known as Cue Sheet information).

Parameters
sessionNumberThe number of the session that should be scanned for index information. To obtain information about the disk sessions use the ReadSessionInfo method.

This method scans the entire session and reads the pre-gap and the track index information from the audio sector sub-channels.

The reading progress is reported via the OnRead event.

Version
1.35
Returns
A CDSession object if successful, otherwise null.
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.ReadCDSessionLayout().

Referenced by Device.ReadCDSessionLayout(), and Device.ReadCDSessionLayout().

◆ ReadCDSessionLayout() [2/3]

CDSession ReadCDSessionLayout ( byte  sessionNumber,
bool  performIndexScan 
)

Extracts a CDSession object from a CD session.

Creates a CDSession object with the track and index information of the extracted session (also known as Cue Sheet information).

Parameters
sessionNumberThe number of the session that should be scanned for index information. To obtain information about the disk sessions use the ReadSessionInfo method.
performIndexScanIndicates that the session tracks should be scanned for index information, pre-gap information, and CD form and mode change points. The PrimoBurner abstraction of a CD form and mode change point is the CDMode class. The default value of this parameter is true.

This method scans the entire session and reads the pre-gap and the track index information from the audio sector sub-channels.

The reading progress is reported via the OnRead event.

Version
1.35
Returns
A CDSession object if successful, otherwise null.
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.ReadCDSessionLayout().

◆ ReadCDSessionLayout() [3/3]

CDSession ReadCDSessionLayout ( byte  sessionNumber,
bool  performIndexScan,
bool  fastScan,
Int32  fastScanBlocks 
)

Extracts a CDSession object from a CD session.

Creates a CDSession object with the track and index information of the extracted session (also known as Cue Sheet information).

Parameters
sessionNumberThe number of the session that should be scanned for index information. To obtain information about the disk sessions use the ReadSessionInfo method.
performIndexScanIndicates that the session tracks should be scanned for index information, pre-gap information, and CD form and mode change points. The PrimoBurner abstraction of a CD form and mode change point is the CDMode class. The default value of this parameter is true.
fastScanIndicates that a fast scan should be performed. When set to true only first 600 blocks from each track are scanned. This parameter has no meaning if performIndexScan is set to false. The default value for this parameter is true.
fastScanBlocksNumber of blocks to scan from each track when scanning for ISRC and MCN information. This parameter has no meaning if fastScan is set to false.

This method scans the entire session and reads the pre-gap and the track index information from the audio sector sub-channels.

The reading progress is reported via the OnRead event.

Version
1.35
Returns
A CDSession object if successful, otherwise null.
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadCDText()

CDText ReadCDText ( )

Reads the CD-TEXT of Audio CD.

Returns
If successful the method returns an object that contains the CD-Text from the media; otherwise null
See also
CDText

◆ ReadData() [1/2]

bool ReadData ( TrackBuffer  trackBuffer,
Int32  startAddress 
)

Reads data from the media.

Reads up to DefaultBufferSize.Cd blocks from the medium.

Parameters
trackBufferUpon successful execution the track buffer will contain the data read from the medium. The TrackBuffer object must be created before calling this method.
startAddressAddress (in blocks) at which to start the reading operation
Version
1.10
Returns
true - Success

false - Error

See also
TrackBuffer
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.ReadData().

Referenced by Device.ReadData().

◆ ReadData() [2/2]

bool ReadData ( TrackBuffer  trackBuffer,
Int32  startAddress,
Int32  blocks 
)

Reads data from the media.

Reads up to DefaultBufferSize.Cd blocks from the medium.

Parameters
trackBufferUpon successful execution the track buffer will contain the data read from the medium. The TrackBuffer object must be created before calling this method.
startAddressAddress (in blocks) at which to start the reading operation
blocksNumber of blocks to be read
Version
1.10
Returns
true - Success

false - Error

See also
TrackBuffer

References TrackBuffer.BlockSize, and TrackBuffer.MaxBlocks.

◆ ReadDiscInfo()

DiscInfo ReadDiscInfo ( )

Reads information about the disk.

This method works even when the last session on the disk is empty or incomplete.

Version
1.11
Returns
Upon successful execution the method retuns a DiscInfo object, otherwise returns null.
See also
DiscInfo
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadMediaInfo()

MediaInfo ReadMediaInfo ( )

Retrieves extended information from the media in the device.

Version
1.74
Returns
A PrimoSoftware.Burner.MediaInfo object. The object must freed with the MediaInfo.Dispose method.
See also
MediaInfo
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadRawToc()

RawToc ReadRawToc ( )

Reads the Full Table-Of-Content in raw format.

This method returns all Q sub-code data in the Lead-In (TOC) area. For multi-session discs, the TOC data for all sessions is returned.

Version
1.21
Returns
Returns a RawToc object upon successful execution, otherwise returns null.
See also
RawToc, RawTocTrack
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadSessionInfo()

SessionInfo ReadSessionInfo ( )

Returns information about the disc sessions.

This method reports only the complete sessions. If the last session on the disc is in an incomplete state, the session will be ignored. The method will fail if there is only one session on the disc and it is in an incomplete state.

Version
1.11
Returns
Upon successful execution returns a SessionInfo object, otherwise returns null
See also
Device.Error
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadToc()

Toc ReadToc ( )

Reads the Table-Of-Content of a CD.

For multi-session discs, this command returns the TOC data for all complete sessions.

This method reports only the tracks from the complete sessions. If the last session on the disc is incomplete that session is ignored. The method will fail if there is only one session on the disc and it is an incomplete one.

Returns
A Toc object containing the requested Table-Of-Content details, or null if the TOC could not be fetched (check Device.Error).
See also
Toc, TocTrack
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadTocFromSession()

Toc ReadTocFromSession ( byte  sessionNumber)

Reads the Table-Of-Content of a session.

Parameters
sessionNumberSpecifies the session number for which the data is returned. If this value is set to zero, the Table of Contents will start with the first track on the disc.

The track with index = AAh contains the start of the lead-out area of the last complete session on the disc.

Version
1.10
Returns
If successful returns an object containing the Table-Of-Content information for the specified session, otherwise returns null.
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadTrackInfoEx()

TrackInfoEx ReadTrackInfoEx ( Int32  trackNumber)

Returns extended information about a track.

This methods works for any track including the tracks that have not been closed and the tracks which are in open sessions.

Parameters
trackNumberThe number of the track to return information for. For CD media the value of this parameter should be a number between 1 and 99.
Version
1.51
Returns
A TrackInfoEx structure filled in with the extended track information or null if an error occured.
See also
TrackInfoEx
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Refresh()

void Refresh ( )

The Refresh method re-reads disc information.

Use this method right after the device tray was closed.

NOTE: This method also tries to dismount the volume in the device. That forces the operating system to invalidate its cache and to refresh the information about the cd file system.

Version
1.2
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReserveTrack()

bool ReserveTrack ( Int32  blocks)

Reserves a track.

For CD the track size must be 300 blocks or more.

Parameters
blocksThe size in blocks of the reserved track.

Use after Device.StartCDSession/StartDVDSession

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReserveTrackLBA()

bool ReserveTrackLBA ( Int32  endLBA)

Reserves a track by specifying the end logical block address instead of size.

For CD the LBA must be such that the size of the reserved track to be 300 or more.

Parameters
endLBAThe end logical block address to use.

Use after Device.StartCDSession/StartDVDSession

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Reset()

bool Reset ( )

The Reset method resets the device firmware.

Use this method to reset the device when a writing operation failed.

Version
1.11
Returns
true - reset successful

false - reset failed

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ SetCDText()

bool SetCDText ( CDText  cdText)

Sets the CD-TEXT data that should be written to the CD.

This method must be called before the StartCDSession method.

Parameters
cdTextSet this parameter to null if you do not want CD-TEXT to be written on the CD, otherwise set teh desired CD Text data

CD-TEXT data is encoded in the lead in area of the CD. CD-TEXT is not supported in TAO, RAW DAO and RAW SAO modes.

Version
1.10


Returns
true - CD-Text data successfully set; false - failed tio set CD Text data
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ StartBDSession()

bool StartBDSession ( )

The StartBDSession method initializes a new Blu-ray Disc session.

Version
2.00
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ StartBDTrack()

bool StartBDTrack ( Int32  blocks)

The StartBDTrack method starts a new track or continues and existing track from a BD session.

Parameters
blocksNumber of BD blocks to be added to the track. The size of one BD block is 2048 bytes. An open track may consume all remaining available blocks on the disc.

This method should be called after the StartBDSession method and before the EndBDTrack method.

Version
2.00
Returns
true - Success.

false - Failure.

See also
Device.EndBDTrack
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ StartCDSession() [1/3]

bool StartCDSession ( bool  simulate,
CDSession  session 
)

Starts the recording of a new CD session.

Parameters
simulateIndicates whether a simulated burn should be performed. The simulation is a good test of a device, because most of the operations are performed as in a real burn. If this parameter is true, the burn is simulated and nothing is burned on the CD. If this parameter is set to false the burn is real.
sessionA CDSession object that contains the session definition. The CDSession object is used to create a Table-Of-Content (TOC) record on the CD and to drive the burning process. The CDSession object determines also the type of the CD session (i.e. Audio, Data, CD-XA, RAW) and the mode of each track (via the CDTrack.Type property).

The method starts recording the specified CD session using WriteMethod.Sao. The session is always closed when any of the SAO write methods are used.

The following rules apply to the CDSession object depending on the selected write method:

WriteMethod.Sao, WriteMethod.FullRawDao, WriteMethod.RawDao2352 and WriteMethod.RawDao: The CDSession object specified with the ‘session’ parameter determines the type and the structure of the session and should contain valid CDTrack items for all tracks in the session.

WriteMethod.Tao and WriteMethod.Packet: The CDSession object specified with the ‘session’ parameter determines the type of the session only and should not contain any CDTrack items. Parameters of each track are additionally specified when a new track is initiated using the StartCDTrack method.

Version
1.20
Returns
true - Success.

false - Failure.

See also
Device.EndCDSession
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.StartCDSession().

Referenced by Device.StartCDSession(), and Device.StartCDSession().

◆ StartCDSession() [2/3]

bool StartCDSession ( bool  simulate,
CDSession  session,
WriteMethod  wm 
)

Starts the recording of a new CD session.

Parameters
simulateIndicates whether a simulated burn should be performed. The simulation is a good test of a device, because most of the operations are performed as in a real burn. If this parameter is true, the burn is simulated and nothing is burned on the CD. If this parameter is set to false the burn is real.
sessionA CDSession object that contains the session definition. The CDSession object is used to create a Table-Of-Content (TOC) record on the CD and to drive the burning process. The CDSession object determines also the type of the CD session (i.e. Audio, Data, CD-XA, RAW) and the mode of each track (via the CDTrack.Type property).
wmDetermines the write method that should be used to burn the CD session. See the WriteMethod enumeration for a list of the supported write methods.

The following rules apply to the CDSession object depending on the selected write method:

WriteMethod.Sao, WriteMethod.FullRawDao, WriteMethod.RawDao2352 and WriteMethod.RawDao: The CDSession object specified with the ‘session’ parameter determines the type and the structure of the session and should contain valid CDTrack items for all tracks in the session.

WriteMethod.Tao and WriteMethod.Packet: The CDSession object specified with the ‘session’ parameter determines the type of the session only and should not contain any CDTrack items. Parameters of each track are additionally specified when a new track is initiated using the StartCDTrack method.

Version
1.20
Returns
true - Success.

false - Failure.

See also
Device.EndCDSession
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.StartCDSession().

◆ StartCDSession() [3/3]

bool StartCDSession ( bool  simulate,
CDSession  session,
WriteMethod  wm,
bool  closeSession,
bool  closeDisc 
)

Starts the recording of a new CD session.

Parameters
simulateIndicates whether a simulated burn should be performed. The simulation is a good test of a device, because most of the operations are performed as in a real burn. If this parameter is true, the burn is simulated and nothing is burned on the CD. If this parameter is set to false the burn is real.
sessionA CDSession object that contains the session definition. The CDSession object is used to create a Table-Of-Content (TOC) record on the CD and to drive the burning process. The CDSession object determines also the type of the CD session (i.e. Audio, Data, CD-XA, RAW) and the mode of each track (via the CDTrack.Type property).
wmDetermines the write method that should be used to burn the CD session. See the WriteMethod enumeration for a list of the supported write methods.
closeSessionIndicates whether the session should be closed. Set to false to leave the session open and to allow additional tracks to be added to the session at a later time. This parameter is ignored when the write method is WriteMethod.Sao. The session is always closed when any of the SAO write methods are used. This parameter is ignored if WriteMethod.FullRawDao or WriteMethod.RawDao2352 methods are used. The default value of this parameter is "true".
closeDiscIndicates whether the CD should be closed. Set this parameter to false to allow additional sessions to be added at later time to the disc. This parameter is ignored if there is raw B0 point set in the session and the write method is set to WriteMethod.FullRawDao and in WriteMethod.RawDao2352. The default value of this parameter is "true".

The following rules apply to the CDSession object depending on the selected write method:

WriteMethod.Sao, WriteMethod.FullRawDao, WriteMethod.RawDao2352 and WriteMethod.RawDao: The CDSession object specified with the ‘session’ parameter determines the type and the structure of the session and should contain valid CDTrack items for all tracks in the session.

WriteMethod.Tao and WriteMethod.Packet: The CDSession object specified with the ‘session’ parameter determines the type of the session only and should not contain any CDTrack items. Parameters of each track are additionally specified when a new track is initiated using the StartCDTrack method.

Version
1.20
Returns
true - Success.

false - Failure.

See also
Device.EndCDSession
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ StartCDTrack()

bool StartCDTrack ( CDTrack  newTrack)

Starts a new track on a TAO or Packet session.

This method does nothing if the write mode is different than WriteMethod.Tao or
WriteMethod.Packet.

<para>The following rules apply to the type of the new track:</para>

<para>1) Type cannot be <see cref="TrackType">TrackType.ModeRaw</see> when in StartCDSession method, the write method is set to <see cref="WriteMethod">WriteMethod.Tao</see>.</para>

<para>2) Type cannot be <see cref="TrackType">TrackType.ModeRaw</see> or <see cref="TrackType">TrackType.Audio</see> when in StartCDSession, the write method is set to <see cref="WriteMethod">WriteMethod.Packet</see>.</para>

<para>3) No pregap or postgap should be defined.</para>

<para>4) The track start should be 0.</para>

<para>5) The track end should be the length of the track in blocks.</para>
Parameters
newTrackA CDTrack object. The track start should be set to 0 and the track end should be set to the length of the track in blocks. The new track is added to the session object that which is passed to the Device.StartCDSession method during the session initialization.
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ StartDVDSession() [1/3]

bool StartDVDSession ( bool  simulate)

Initializes a new DVD session.

Parameters
simulateIndicates whether a simulated burn should be performed. The simulation is a good test of a device, because most of the operations are performed as in a real burn. If this parameter is true, the burn is simulated and nothing is burned on the DVD. If this parameter is set to false the burn is real.

The method will use WriteMethod.DvdIncremental and will close the session once its recording is done.

Media Specific Details:

* DVD-R and DVD+R

It is possible to use both Disc-At-Once (WriteMethod.DvdDao) and Incremental (WriteMethod.DvdIncremental) methods with DVD-R. WriteMethod.DvdDao cannot be used with DVD+R media.

When using the WriteMethod.DvdIncremental the multi-session structure of the disc is similar to the one of a CD-R. The disc can contain several sessions with multiple tracks in each session.

* DVD-RW

It is possible to use both Disc-At-Once (WriteMethod.DvdDao) and Incremental (WriteMethod.DvdIncremental) methods with DVD-RW.

DVD-RW can be configured as sequential recording media or a restricted overwrite media. By default a new blank DVD-RW configured as a sequential recording media.

If a DVD-RW disc is formatted it becomes a Restricted Overwrite media and can only be written with the Incremental (WriteMethod.DvdIncremental) method.
The Disc-At-Once (WriteMethod.DvdDao) method cannot be used on restricted overwrite media. Fully blanking a DVD-RW will make it a sequential and formatting it a restricted overwrite disc. Use the Format method to format a DVD-RW and Erase to erase/blank it.

When DVD-RW Restricted Overwrite media is burned using the WriteMethod.DvdIncremental method multiple sessions are possible but each session contains only one track and new data is added to the same track until the session is closed.

When DVD-RW Sequential media is burned using the WriteMethod.DvdIncremental method the sessions can have one or more tracks.

* DVD+RW

Only Incremental (WriteMethod.DvdIncremental) method can be used with DVD+RW media. There is no multi-session in a traditional sense. The applications could write anywhere on the disc as long as it is formatted.

Notes:

The DVD-R specification describes entities called Lead-in, Lead-out, Border-in and Border-out. DVD-R always has zero or one Lead-in and zero or one Lead-out. The Lead-in, if recorded, is always at the beginning of the disc and the Lead-out, if recorded, is always at the end of the disc. No data can be recorded beyond the Lead-out. The information recording area is a collection of Lead-in/Border-in, Bordered Areas, and Border-out/Lead-out. The bordered area, when written, is called a complete session.

If only a Border-in and Border-out are to be written (after incrementally recording data), the calling application should set the 'closeDisc' parameter to false. If set to false, and insufficient space exists on the medium for another Border, the device will permanently close the medium by recording a Lead-out.

To be consistent with the sessions and tracks concept, in PrimoBurner SDK, the standard Multi-session is used instead of Multi-Border, incomplete session is used instead of incomplete Border and complete session is used instead of complete Border for DVD-R devices.

DVD media is 2KB addressable but the actual writing is done using 32KB packets. The PrimoBurner and the device itself take care of data packing and alignment internally. For the calling application the DVD writing process is similar to the writing of a MODE1 CD (Data CD) except that the StartDVDSession and the StartDVDTrack methods should be used to initiate a DVD session and track and the EndDVDTrack and EndDVDSession methods to finalize it.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.StartDVDSession().

Referenced by Device.StartDVDSession(), and Device.StartDVDSession().

◆ StartDVDSession() [2/3]

bool StartDVDSession ( bool  simulate,
WriteMethod  writeMethod 
)

Initializes a new DVD session.

Parameters
simulateIndicates whether a simulated burn should be performed. The simulation is a good test of a device, because most of the operations are performed as in a real burn. If this parameter is true, the burn is simulated and nothing is burned on the DVD. If this parameter is set to false the burn is real.
writeMethodDetermines the write method that should be used while burning a DVD session.
The valid write methods for DVD are: Incremental (WriteMethod.DvdIncremental) and Disc-At-Once (WriteMethod.DvdDao). The default value of this parameter is WriteMethod.DvdIncremental.

The WriteMethod.DvdIncremental method works with all DVD media profiles - DVD+RW/+R/-RW/-R.
The burning is done in sessions and fragments (tracks) with one exception for DVD+RW media: DVD+RW disc needs to be formatted before any burning could be done and once formatted the disc contains one session and one track and the whole track could be written and rewritten randomly with no overwrite restrictions.

With WriteMethod.DvdDao the disc will contain one session with one track. No sessions could be added after the burning is completed. The WriteMethod.DvdDao can be used only with DVD-RW media formatted for sequential writing and DVD-R media. It is recommended to use the WriteMethod.DvdDao and DVD-R media to burn DVD movies to ensure best compatibility with the consumer DVD players.

The method will close the session once its recording is done.

Media Specific Details:

* DVD-R and DVD+R

It is possible to use both Disc-At-Once (WriteMethod.DvdDao) and
Incremental (WriteMethod.DvdIncremental) methods with DVD-R. WriteMethod.DvdDao cannot be used with DVD+R media.

When using the WriteMethod.DvdIncremental the multi-session structure of the disc is similar to the one of a CD-R. The disc can contain several sessions with multiple tracks in each session.

* DVD-RW

It is possible to use both Disc-At-Once (WriteMethod.DvdDao) and
Incremental (WriteMethod.DvdIncremental) methods with DVD-RW.

DVD-RW can be configured as sequential recording media or a restricted overwrite media. By default a new blank DVD-RW configured as a sequential recording media.

If a DVD-RW disc is formatted it becomes a Restricted Overwrite media and can only be written with the Incremental (WriteMethod.DvdIncremental) method.
The Disc-At-Once (WriteMethod.DvdDao) method cannot be used on restricted overwrite media. Fully blanking a DVD-RW will make it a sequential and formatting it a restricted overwrite disc. Use the Format method to format a DVD-RW and Erase to erase/blank it.

When DVD-RW Restricted Overwrite media is burned using the WriteMethod.DvdIncremental method multiple sessions are possible but each session contains only one track and new data is added to the same track until the session is closed.

When DVD-RW Sequential media is burned using the WriteMethod.DvdIncremental method the sessions can have one or more tracks.

* DVD+RW

Only Incremental (WriteMethod.DvdIncremental) method can be used with DVD+RW media. There is no multi-session in a traditional sense. The applications could write anywhere on the disc as long as it is formatted.

Notes:

The DVD-R specification describes entities called Lead-in, Lead-out, Border-in and Border-out. DVD-R always has zero or one Lead-in and zero or one Lead-out. The Lead-in, if recorded, is always at the beginning of the disc and the Lead-out, if recorded, is always at the end of the disc. No data can be recorded beyond the Lead-out. The information recording area is a collection of Lead-in/Border-in, Bordered Areas, and Border-out/Lead-out. The bordered area, when written, is called a complete session.


If only a Border-in and Border-out are to be written (after incrementally recording data), the calling application should set the 'closeDisc' parameter to false. If set to false, and insufficient space exists on the medium for another Border, the device will permanently close the medium by recording a Lead-out.

To be consistent with the sessions and tracks concept, in PrimoBurner SDK, the standard Multi-session is used instead of Multi-Border, incomplete session is used instead of incomplete Border and complete session is used instead of complete Border for DVD-R devices.

DVD media is 2KB addressable but the actual writing is done using 32KB packets. The PrimoBurner and the device itself take care of data packing and alignment internally. For the calling application the DVD writing process is similar to the writing of a MODE1 CD (Data CD) except that the StartDVDSession and the StartDVDTrack methods should be used to initiate a DVD session and track and the EndDVDTrack and EndDVDSession methods to finalize it.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

References Device.StartDVDSession().

◆ StartDVDSession() [3/3]

bool StartDVDSession ( bool  simulate,
WriteMethod  writeMethod,
bool  closeDisc 
)

Initializes a new DVD session.

Parameters
simulateIndicates whether a simulated burn should be performed. The simulation is a good test of a device, because most of the operations are performed as in a real burn. If this parameter is true, the burn is simulated and nothing is burned on the DVD. If this parameter is set to false the burn is real.
writeMethodDetermines the write method that should be used while burning a DVD session. The valid write methods for DVD are: Incremental (WriteMethod.DvdIncremental) and Disc-At-Once (WriteMethod.DvdDao). The default value of this parameter is WriteMethod.DvdIncremental.

The WriteMethod.DvdIncremental method works with all DVD media profiles - DVD+RW/+R/-RW/-R. The burning is done in sessions and fragments (tracks) with one exception for DVD+RW media:

DVD+RW disc needs to be formatted before any burning could be done and once formatted the disc contains one session and one track and the whole track could be written and rewritten randomly with no overwrite restrictions.

With WriteMethod.DvdDao the disc will contain one session with one track. No sessions could be added after the burning is completed. The WriteMethod.DvdDao can be used only with DVD-RW media formatted for sequential writing and DVD-R media. It is recommended to use the WriteMethod.DvdDao and DVD-R media to burn DVD movies to ensure best compatibility with the consumer DVD players.

Parameters
closeDiscIndicates whether the DVD disc should be closed. Set this parameter to false to allow additional sessions to be added at later time to the disc. When burning DVD Video always set 'closeDisc' to true to ensure compatibility with all consumer DVD players. On DVD-R, when WriteMethod.DvdDao is used, the disc is always closed and a lead-out is written at the end of it. The default value of this parameter is "true".

Media Specific Details:

* DVD-R and DVD+R

It is possible to use both Disc-At-Once (WriteMethod.DvdDao) and Incremental (WriteMethod.DvdIncremental) methods with DVD-R. WriteMethod.DvdDao cannot be used with DVD+R media.

When using the WriteMethod.DvdIncremental the multi-session structure of the disc is similar to the one of a CD-R. The disc can contain several sessions with multiple tracks in each session.

* DVD-RW

It is possible to use both Disc-At-Once (WriteMethod.DvdDao) and Incremental (WriteMethod.DvdIncremental) methods with DVD-RW.

DVD-RW can be configured as sequential recording media or a restricted overwrite media. By default a new blank DVD-RW configured as a sequential recording media.

If a DVD-RW disc is formatted it becomes a Restricted Overwrite media and can only be written with the Incremental (WriteMethod.DvdIncremental) method. The Disc-At-Once (WriteMethod.DvdDao) method cannot be used on restricted overwrite media. Fully blanking a DVD-RW will make it a sequential and formatting it a restricted overwrite disc. Use the Format method to format a DVD-RW and Erase to erase/blank it.

When DVD-RW Restricted Overwrite media is burned using the WriteMethod.DvdIncremental method multiple sessions are possible but each session contains only one track and new data is added to the same track until the session is closed.

When DVD-RW Sequential media is burned using the WriteMethod.DvdIncremental method the sessions can have one or more tracks.

* DVD+RW

Only Incremental (WriteMethod.DvdIncremental) method can be used with DVD+RW media. There is no multi-session in a traditional sense. The applications could write anywhere on the disc as long as it is formatted.

Notes:

The DVD-R specification describes entities called Lead-in, Lead-out, Border-in and Border-out. DVD-R always has zero or one Lead-in and zero or one Lead-out. The Lead-in, if recorded, is always at the beginning of the disc and the Lead-out, if recorded, is always at the end of the disc. No data can be recorded beyond the Lead-out. The information recording area is a collection of Lead-in/Border-in, Bordered Areas, and Border-out/Lead-out. The bordered area, when written, is called a complete session.

If only a Border-in and Border-out are to be written (after incrementally recording data), the calling application should set the 'closeDisc' parameter to false. If set to false, and insufficient space exists on the medium for another Border, the device will permanently close the medium by recording a Lead-out.

To be consistent with the sessions and tracks concept, in PrimoBurner SDK, the standard Multi-session is used instead of Multi-Border, incomplete session is used instead of incomplete Border and complete session is used instead of complete Border for DVD-R devices.

DVD media is 2KB addressable but the actual writing is done using 32KB packets. The PrimoBurner and the device itself take care of data packing and alignment internally. For the calling application the DVD writing process is similar to the writing of a MODE1 CD (Data CD) except that the StartDVDSession and the StartDVDTrack methods should be used to initiate a DVD session and track and the EndDVDTrack and EndDVDSession methods to finalize it.

Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ StartDVDTrack()

bool StartDVDTrack ( Int32  blocks)

Starts a new track or continues an existing track from a DVD session.

This method should be called after the Device.StartDVDSession method and before the Device.EndDVDTrack method.

Parameters
blocksNumber of DVD blocks to be added to the track. The size of one DVD block is 2048 bytes. An open track may consume all remaining available blocks on the DVD.

NOTES:

DVD-R Sequential, DVD-RW in Sequential mode, and DVD-RW in Restricted Overwrite mode - if blocks is less than 65264 blocks, for the first track only, the device will automatically pad the track to a size of 65264 blocks.

On DVD-RW in Restricted Overwrite mode - if Required Space > Formatted Space, then the last formatted session will be expanded by (Required Space - Formatted Space) blocks, where Required Space = (NewSessionStartAddress + blocks), and Formatted Space = (MediaCapacity - MediaFreeSpace).

Returns
true - Success.

false - Failure.

See also
Device.EndDVDTrack
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ UnlockOutputBuffer()

void UnlockOutputBuffer ( Int32  blocks)

Unlocks the write buffer and writes the data from the buffer to the disc.

Parameters
blocksNumber of blocks actually written to the buffer1 and buffer2 returned by the LockOutputBuffer method. It should not exceed the number of blocks requested with the LockOutputBuffer method.
See also
Device.LockOutputBuffer, Device.ClearOutputBuffer
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ UnlockOutputBufferEx()

void UnlockOutputBufferEx ( Int32  blocks,
Int32  discAddress 
)

Unlocks the write buffer and writes the data from the buffer to the disc.

WARNING. USE WITH CAUTION:

Usage of this method requires thorough understanding of DVD physical format and specifications. Improper use may result in errors during writing or even data loss on DVD+RW/-RW media.

Parameters
blocksNumber of blocks actually written to the buffer1 and buffer2 returned by the LockOutputBuffer method. It should not exceed the number of blocks requested with the LockOutputBuffer method.
discAddressThe address to which the block of data should be written. This parameter is ignored for CD-R and CD-RW media. For CD-R and CD-RW media the engine always manages the disc addresses automatically.
See also
Device.LockOutputBuffer, Device.ClearOutputBuffer
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ WriteData()

bool WriteData ( Int32  startLba,
byte[]  buffer,
Int32  blocks,
Int32  blockSize 
)

The WriteData method writes data to a CD, DVD or BD starting at the logical block address indicated by the startLba parameter.

Parameters
startLbaThe logical block address at which the writing should start
bufferPointer to a buffer that contains the data to be written.
blocksThe number of blocks that should be written.
blockSizeThe size of the data block.
Returns
true - Success.

false - Failure.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

Property Documentation

◆ BDFeatures

Returns a BDFeatures object describing the Blu-ray Disc capabilities of the device.

Version
2.08

◆ BDWriteVerify

bool BDWriteVerify
getset

Indicates whether the device should do automatic verify-after-write cycle while writing data to BD media.

The default value is false. Valid only for BD-R and BD-RE media. Setting this property has no effect if the media in the device is not Blu-ray Disc.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ BgFormatProgress

double BgFormatProgress
get

Gets the background format progress as a percentage.

If a background format is not running the property returns 0.0. This property returns 0.0 for DVD-RW media.

See also
Device.BgFormatStatus, Device.Format
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ BgFormatStatus

Gets the background format status of the mounted disc.

See also
PrimoSoftware.Burner.BgFormatStatus, PrimoSoftware.Burner.Device.Format
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ CDFeatures

Returns a CDFeatures object describing the CD capabilities of the device.

Version
2.53

◆ Description

string Description
get

Gets the device description as it is set by its manufacturer.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ DriveLetter

char DriveLetter
get

Gets the device drive letter.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ DVDFeatures

Returns a DVDFeatures object describing the DVD capabilities of the device.

Version
2.08

◆ DVDWriteVerify

bool DVDWriteVerify
getset

Indicates whether the device should do automatic verify-after-write cycle while writing data to DVD media.

The default value is false. Valid only for DVD-RAM media. This property has no effect if the media in the device is not a DVD-RAM disc.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ EraseProgress

double EraseProgress
get

Gets/sets a percentage showing the progress of an erase operation started with the Device.Erase method.

See also
Device.Erase
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Error

ErrorInfo Error
get

Returns information about the last error that occurred while using the Device object.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ FormatProgress

double FormatProgress
get

Gets/sets a percentage showing the progress of a format operation started with the Device.Format method.

See also
Device.Format
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Handle

IntPtr Handle
get

Gets the operating system device handle.

Returns
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ InternalCacheCapacity

Int32 InternalCacheCapacity
get

Gets the capacity of the device internal cache buffer.

The internal cache is a memory cache built in the CD-ROM device.

Most of the modern devices use from 1 to 4 MB of RAM for cache.

Version
1.10
See also
Device.InternalCacheUsedSpace

◆ InternalCacheUsedSpace

Int32 InternalCacheUsedSpace
get

Gets the number of bytes used in the device internal cache.

The internal cache is a memory cache built in the CD-ROM device. Most of the modern devices use from 1 to 4 MB of RAM for cache. The InternalCacheUsedSpace property should be used only during the burning process.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MaxReadSpeedKB

Int32 MaxReadSpeedKB
get

Gets the maximum supported read speed in Kbytes/s.

The value of this property depends on the media that is in the device.

To get the speed relative to 1x divide the result to Speed1xKB.CD, Speed1xKB.DVD, or Speed1xKB.BD.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MaxWriteSpeedKB

Int32 MaxWriteSpeedKB
get

Gets the maximum supported write speed in Kbytes/s.

The value of this property depends on the media that is in the device.

To get the speed relative to 1x divide the result to Speed1xKB.CD, Speed1xKB.DVD, or Speed1xKB.BD.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaCapacity

Int64 MediaCapacity
get

Gets the block capacity of the media inserted in the device.

The actual byte capacity depends on the block size that will be used during the burning. Different media capacity may be reported than the full size of the disc when the disc in the device is complete (closed).

To determine whether the disc has free space available for writing use the MediaFreeSpace property.

NOTE: If the media is unformatted BD-RE and DVD+RW, this method returns the blank disc capacity.

Version
1.61
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaFreeSpace

Int64 MediaFreeSpace
get

Gets the numbers of blocks that can be added to the disc in the device before an additional add will cause a failure for lack of space.

NOTE: For formatted DVD+RW and BD-RE media all disc space is reported as free (available) regardless of what is recorded on the disc. That is because once formatted the DVD+RW and BD-RE discs become unrestricted-overwrite random-writable media.

For DVD-RW in Restricted Overwrite mode (a.k.a. DVD-RW RO) the reported value is the number of blocks that have not been formatted. If the disc is fully formatted DVD-RW the reported free space is 0. However, the disc can still be written to.

Version
1.61
See also
NewSessionStartAddress
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaIsBD

bool MediaIsBD
get

Indicates whether the media in the device is BD-R or BD-RE.

Version
2.00
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaIsBlank

bool MediaIsBlank
get

Indicates that the media in the device is blank.

Formatted DVD-RAM, DVD+RW, and Restricted Overwrite DVD-RW are not blank.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaIsCD

bool MediaIsCD
get

Indicates whether the media in the device is CD-ROM, CD-R or CD-RW.

Version
2.00
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaIsDVD

bool MediaIsDVD
get

Indicates whether the medium in the device is DVD-ROM, DVD-RAM, DVD-R/RW or DVD+R/RW.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaIsFormatted

bool MediaIsFormatted
get

Indicates whether the media in the device is formatted.

NOTES:

DVD-RW for Restricted Overwrite: returns true only when the DVD-RW disc is fully formatted.

DVD+RW: returns true only when the DVD+RW disc is fully formatted.

Retuns true if the media in the device is a fully formatted disc.

Returns false if the media in the device is blank unformatted disc, or the media is partially formatted or a background format is currently pending.

Version
2.00
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaIsReWritable

bool MediaIsReWritable
get

Indicates whether the media in the device is re-writable.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaLayerCapacity

Int64 MediaLayerCapacity
get

Returns the layer 0 (L0) capacity, in blocks, of DVD-R DL and DVD+R DL media.

Returns 0 for all other media types.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaProfile

Gets the type of the media that is currently inserted in the device.

See also
PrimoSoftware.Burner.MediaProfile
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ MediaState

MediaReady MediaState
get

Indicates whether there is medium inserted in the device.

See also
MediaReady
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ NewSessionStartAddress

Int32 NewSessionStartAddress
getset

Gets/Sets the start address of the new disc session.

NOTES:

This property should be set for random writable media like DVD+RW where all the space on the media is always available for writing. This property should be set before calling the StartDVDSession method.

If the last session is open (incomplete) this property returns the start address of the incomplete session.

This property should be used with random writable media like formatted DVD+RW, formatted DVD-RW or DVD-RAM, and formatted BD-RE media. For all other media types the engine determines and uses the correct start address internally.

For DVD+RW, DVD-RAM and BD-RE the calling application should set the start address because there is no other way to know what part of the media is written and what part is available.

On DVD+RW, DVD-RW RO, DVD-RAM and BD-RE the disc space is managed on a higher level by the file system used for the DVD disc, such as UDF, Joliet or ISO.

DVD special cases:

  • On DVD+RW disc, all space is available for writing. The GetNewSessionStartAddress and NewTrackStartAddress methods always return 0 for DVD+RW media.
  • For DVD-RW which has been formatted for restricted overwrite (i.e. DVD-RW RO) NewSessionStartAddress and NewTrackStartAddress methods return 0.
See also
DataDisc.SessionStartAddress, Device.MediaFreeSpace
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ NewTrackStartAddress

Int32 NewTrackStartAddress
get

Gets the start address of the next disc track.

Using this property makes sense only when there is some free space on the disc and when the last session on the disc is not complete (has been left open).

To check if there is any free space on the disc use the MediaFreeSpace property. You can use the ReadDiscInfo method to see if the last session on the disk is incomplete.

If the last track in the last session is open (incomplete) this property returns the start address of the last incomplete track + the number of sectors recorded from the incomplete track.

DVD special cases:

  • On DVD+RW disc, all space is available for writing. The NewSessionStartAddress and NewTrackStartAddress properties always return 0 for DVD+RW media.
  • For DVD-RW which has been formatted for restricted overwrite (i.e. DVD-RW RO) NewSessionStartAddress and NewTrackStartAddress properties return 0.
Version
1.11
See also
DataDisc.SessionStartAddress
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ProductId

string ProductId
get

Gets the product id (the model) of the device as it is set by its manufacturer.

Version
1.10
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ReadSpeedKB

Int32 ReadSpeedKB
getset

Gets/Sets the read speed in Kbytes/s.

1 Kbyte = 1000 bytes.

To get the speed relative to 1x divide the result to Speed1xKB.CD, Speed1xKB.DVD, or Speed1xKB.BD.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Revision

string Revision
get

Gets the revision (the version) of the device's firmware as it is set by its manufacturer.

Version
1.10
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ ScsiAddress

string ScsiAddress
get

Gets the SCSI bus address of the device as string in the form of (Host Adapter Number:Target ID:LUN)

Host Adapter Number - This field specifies which installed host adapter the request is intended for. Host adapter numbers are assigned by the SCSI manager layer, beginning with 0.

Target ID - This field indicates the SCSI ID of the target device.

LUN - This field indicates the Logical Unit Number (LUN) of the device

Version
1.10

◆ Streaming

bool Streaming
getset

Indicates whether the device should use stream recording or not.

The default value is false. Valid only for BD-R and BD-RE media. Setting this property has no effect if the media in the device is not Blu-ray Disc.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ SystemPath

String SystemPath
get

Returns the system path that identifies the device.

Version
3.6.2
See also
DeviceEnumerator.CreateDeviceFromSystemPath

◆ UnitReady

Int32 UnitReady
get

Indicates whether the device is ready.

Returns DeviceError.Success if the device is ready, or a status code indicating the device condition. The status codes are defined in the DeviceError enumeration.

Version
1.50
See also
PrimoSoftware.Burner.DeviceError
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ Vendor

string Vendor
get

Gets the device vendor name as set by the manufacturer.

Version
1.10
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ VendorSpecificInfo

string VendorSpecificInfo
get

Gets the vendor specific information of the device as it is set by its manufacturer.

Version
1.10

◆ WriteSpeedKB

Int32 WriteSpeedKB
getset

Gets/Sets the write speed in Kbytes/s.

The speed in Kbytes is the x speed (1x, 2x ...) multiplied by Speed1xKB.CD, Speed1xKB.DVD, or Speed1xKB.BD. 1 Kbyte = 1000 bytes.

To get a list of all the write speeds supported by a device use the Device.GetWriteSpeeds method.

See also
Device.GetWriteSpeeds
Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

◆ WriteTransferRate

Int32 WriteTransferRate
get

Gets the actual write transfer rate (write speed) as measured by PrimoBurner.

Teh rate is in in KB/s (kilobytes/sec).

To calculate the actual write speed divide the result to the rates defined in the Speed1xKB enumeration.

Exceptions
ObjectDisposedExceptionThe Device object was already disposed.

Event Documentation

◆ OnContinueRead

EventHandler<DeviceContinueEventArgs> OnContinueRead

Raised to check if a long read operation should continue.

See also
DeviceContinueEventArgs

◆ OnErase

EventHandler<DeviceEraseEventArgs> OnErase

Raised to report the progress of a disc blanking operation started with the Erase method.

The event handler receives an argument of type DeviceEraseEventArgs containing data related to this event.

See also
DeviceEraseEventArgs

◆ OnFormat

EventHandler<DeviceFormatEventArgs> OnFormat

Raised to report the progress of a format operation started with the Format method.

The event handler receives an argument of type DeviceFormatEventArgs containing data related to this event.

See also
DeviceFormatEventArgs

◆ OnRead

EventHandler<DeviceReadEventArgs> OnRead

Raised to report the progress of long read operations.

The event handler receives an argument of type DeviceReadEventArgs containing data related to this event.

◆ OnWriteLeadIn

EventHandler<DeviceWriteLeadInEventArgs> OnWriteLeadIn

Raised to report the progress during the recording of the lead-in area of a CD session.

when RAW CD writng is used.

NOTE: The lead-in area is written directly by PrimoBurner only when all of the following conditions are met:

  1. The medium is a CD.
  2. The write method is RawDao, RawDao2352 or FullRawDao.
  3. The burner device supports RAW CD writing (CDFeatures::canWriteRawDao() is true). In all other cases this notification is not raised.

The event handler receives an argument of type DeviceWriteLeadInEventArgs containing data related to this event.

◆ OnWriteLeadOut

EventHandler<DeviceWriteLeadOutEventArgs> OnWriteLeadOut

Raised to report the progress during the recording of the lead-out area of a CD session when RAW CD writng is used.

NOTE: The lead-out area is written directly by PrimoBurner only when all of the following conditions are met:

  1. The medium is a CD.
  2. The write method is RawDao, RawDao2352 or FullRawDao.
  3. The burner device supports RAW CD writing (CDFeatures::canWriteRawDao() is true). In all other cases this notification is not raised.

The event handler receives an argument of type DeviceWriteLeadOutEventArgs containing data related to this event.

See also
DeviceWriteLeadOutEventArgs