title: Read data from DVD with maximum speed
body: <p>I'm trying to make a disk dump program (like dd) with C language on Windows.
  The program is almost finished, but there is one problem: reading data from DVD is very slow.
  According to the specification, the DVD drive of my PC supports up to 8x reading rate, but my program reads about 5MB/sec (about 4x). I want to read data with maximum speed.</p>
  <p>The algorithm of my program is simple: using win32api CreateFile and ReadFile, like</p>
  <pre><code>src=CreateFileA(&quot;\\\\.\\E:&quot;,GENERIC_READ,FILE_SHARE_READ|FILE_SHARE_WRITE,NULL,OPEN_EXISTING,FILE_ATTRIBUTE_NORMAL,NULL);
  ReadFile(src,buf,buffer_size,&amp;read_ret,NULL);
  </code></pre>
  <p>The buffer size can be set to 20-100MB. I tried to set speed with DeviceIoControl, like</p>
  <pre><code>cdromSetSpeed.RequestType = CdromSetSpeed;
  cdromSetSpeed.ReadSpeed = 0xFFFF; // max speed
  cdromSetSpeed.WriteSpeed = 0xFFFF; // max speed
  cdromSetSpeed.RotationControl = CdromDefaultRotation;
  DeviceIoControl(src,IOCTL_CDROM_SET_SPEED,&amp;cdromSetSpeed,sizeof(cdromSetSpeed),NULL,0,NULL,NULL);
  </code></pre>
  <p>but it had no effect.</p>
  <p>Please tell me if there is any way to read data from DVD with maximum speed.</p>