[wdmaudiodev] Blocky looking metering in SoundForge

  • From: wade <wdawson61@xxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Wed, 12 Nov 2003 10:48:18 -0800 (PST)

I have written an AVStreams capture driver.
I am experiencing a clunky, blocky display in audio applications that provide 
visual metering of the audio signal.  Upon closer inspection,  in Soundforge, 
If I set the "Status Format" to "samples", and record, the  "time recorded" 
field on the record window increments by ~12k samples (48kBytes).  Other audio 
cards increment by MUCH smaller amounts.  I notice that 12k*2channels*2bytes is 
about one AVSream queue's worth of data (6 * 8192k frames).  
I am KsEditing the Allocator structure to allow selection of frame size, but in 
this instance, 6, 8k frames were alloc'd.
I am completing the frames with the following code:
.... transfer the data to the StreamPointerBuffer
 StreamPointer -> StreamHeader -> DataUsed += TransferSize;
 Pin->audioPosition.WriteOffset += TransferSize;
  // Now figure the duration 
   StreamPointer -> StreamHeader ->OptionsFlags = 
   StreamPointer -> StreamHeader->PresentationTime.Numerator = Pin->kstimeNumer;
   StreamPointer -> StreamHeader->PresentationTime.Denominator = 
   StreamPointer -> StreamHeader->Duration = (TransferSize);
   if (STATUS_DEVICE_NOT_READY == (status=KsStreamPointerAdvanceOffsets 
       status = STATUS_PENDING;
    status = STATUS_SUCCESS;
 //   KsStreamPointerUnlock(StreamPointer,FALSE/*(!Pin->streamRunning)*/);
return status;
Any ideas?

Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard

Other related posts: