Class Quantizer
  
  
  
  
  
  Assembly: Melanchall.DryWetMidi.dll
  
  
  Methods
  
  
  Performs additional actions before the new time will be set to an object after search for
nearest grid time.
  
  Declaration
  
    protected virtual TimeProcessingInstruction OnObjectQuantizing(ITimedObject obj, QuantizedTime quantizedTime, IGrid grid, LengthedObjectTarget target, TempoMap tempoMap, QuantizingSettings settings)
   
  Parameters
  
  Returns
  
    
      
        | Type | 
        Description | 
      
    
    
      
        | TimeProcessingInstruction | 
        An object indicating whether the new time should be set to the object
    or not. Also returned object contains that new time. | 
      
    
  
  
  
  Performs additional actions before the new time will be set to an object after search for
random time within bounds defined by 
Bounds.
 
  
  Declaration
  
    protected virtual TimeProcessingInstruction OnObjectRandomizing(ITimedObject obj, long time, LengthedObjectTarget target, TempoMap tempoMap, QuantizingSettings settings)
   
  Parameters
  
  Returns
  
    
      
        | Type | 
        Description | 
      
    
    
      
        | TimeProcessingInstruction | 
        An object indicating whether the new time should be set to the object
    or not. Also returned object contains that new time. | 
      
    
  
  
  
  Quantizes objects using the specified grid.
  
  Declaration
  
    public void Quantize(IEnumerable<ITimedObject> objects, IGrid grid, TempoMap tempoMap, QuantizingSettings settings = null)
   
  Parameters
  
    
      
        | Type | 
        Name | 
        Description | 
      
    
    
      
        | IEnumerable<ITimedObject> | 
        objects | 
        Objects to quantize. | 
      
      
        | IGrid | 
        grid | 
        Grid to use for quantization. | 
      
      
        | TempoMap | 
        tempoMap | 
        Tempo map used to perform time and length conversions. | 
      
      
        | QuantizingSettings | 
        settings | 
        Settings according to which objects should be quantized. | 
      
    
  
  Exceptions
  
    
      
        | Type | 
        Condition | 
      
    
    
      
        | ArgumentNullException | 
        One of the following errors occurred: 
- 
      
objects is null. - 
      
grid is null. - 
      
tempoMap is null. 
  |