Click here to Skip to main content
15,892,797 members
Articles / Programming Languages / C#

SCSI Library in C# - Burn CDs and DVDs, Access Hard Disks, etc.

Rate me:
Please Sign up or sign in to vote.
4.77/5 (48 votes)
19 Jun 2017Ms-PL6 min read 146K   8.1K   146  
Ever wonder how programs like Nero work? They make their own SCSI libraries... like this!
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Runtime.InteropServices;

namespace Scsi.Multimedia
{
	/// <summary>This feature identifies a drive that GetSupport CSS Managed recording on DVDDownload disc. This feature is current only if a recordable DVD-Download disc is loaded.</summary>
	[Description("This feature identifies a drive that GetSupport CSS Managed recording on DVDDownload disc.\r\nThis feature is current only if a recordable DVD-Download disc is loaded.")]
	[StructLayout(LayoutKind.Sequential, Pack = 1)]
	public class DvdCssManagedRecordingFeature : MultimediaFeature
	{
		[DebuggerBrowsable(DebuggerBrowsableState.Never)]
		private static readonly ScsiCommandCode[] __SupportedOperations = Sort(new ScsiCommandCode[] { ScsiCommandCode.ReportKey, ScsiCommandCode.SendDiscStructure, ScsiCommandCode.SendKey });

		public override FeatureSupportKind GetSupport(ScsiCommand command)
		{
			return Array.BinarySearch<ScsiCommandCode>(__SupportedOperations, command.OpCode) >= 0 ? FeatureSupportKind.Mandatory : FeatureSupportKind.None;
		}

		public DvdCssManagedRecordingFeature() : base(FeatureCode.DvdContentScramblingSystemManagedRecording) { }

		[DebuggerBrowsable(DebuggerBrowsableState.Never)]
		private byte _MaximumNumberOfScrambledExtentInformationSeries;
		[DisplayName("Maximum Number of Scrambled Extent Information Series")]
		public byte MaximumNumberOfScrambledExtentInformationSeries { get { return this._MaximumNumberOfScrambledExtentInformationSeries; } set { this._MaximumNumberOfScrambledExtentInformationSeries = value; } }
		[DebuggerBrowsable(DebuggerBrowsableState.Never)]
		private byte byte5;
		[DebuggerBrowsable(DebuggerBrowsableState.Never)]
		private byte byte6;
		[DebuggerBrowsable(DebuggerBrowsableState.Never)]
		private byte byte7;
	}
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Microsoft Public License (Ms-PL)


Written By
United States United States
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions