reb
Class REB_AverageBlurFilter

Object
  extended by common:Generic
      extended by dmj5:DMJ_ConvolutionFilter
          extended by reb:REB_AverageBlurFilter

class 
DMJ_ConvolutionFilter:REB_AverageBlurFilter

Basic blur/smooth filter using the average value.


Ultra Fractal Source

Toggle UF Source Code Display

 class REB_AverageBlurFilter(dmj5.ulb:DMJ_ConvolutionFilter) {
   ; Basic blur/smooth filter using the average value. <br>
     
 public:
   import "common.ulb"
   import "dmj5.ulb"
   
   ; contructor
   func REB_AverageBlurFilter(Generic pparent)
     DMJ_ConvolutionFilter.DMJ_ConvolutionFilter(pparent)
     
     int count = (@p_samples*2+1)
     int elements = sqr(count)
     setLength(m_Offsets, elements)
     setLength(m_Weights, elements)
     m_Multiplier = 0.0
 
     int j = -@p_samples
     int k = 0
     int l = 0
     while (j <= @p_samples)
       k = -@p_samples
       while (k <= @p_samples)
         m_Offsets[l] = (@p_radius*j/@p_samples + flip(@p_radius*k/@p_samples))/100
         m_Weights[l] = 1
         m_Multiplier = m_Multiplier + m_Weights[l]
         l = l + 1
         k = k + 1
       endwhile
       j = j + 1
     endwhile
     m_Multiplier = 1 / m_Multiplier
   endfunc
   
 default:
   title = "Average Blur Filter"
 
   int param v_AverageBlur
     caption = "Version (Average Blur Filter)"
     default = 100
     hint = "This version parameter is used to detect when a change has been made to the formula that is incompatible with the previous version. When that happens, this field will reflect the old version number to alert you to the fact that an alternate rendering is being used."
     visible = @v_AverageBlur < 100
   endparam
 
   float param p_radius
     caption = "Filter Radius"
     default = 0.1
   endparam
   int param p_samples
     caption = "Sample Density"
     default = 2
     min = 1
     max = 9
   endparam
 }
 


Constructor Summary
REB_AverageBlurFilter()
           
REB_AverageBlurFilter(Generic pparent)
          contructor
 
Method Summary
 
Methods inherited from class dmj5:DMJ_ConvolutionFilter
Init
 
Methods inherited from class common:Generic
GetParent
 
Methods inherited from class Object
 

Constructor Detail

REB_AverageBlurFilter

public REB_AverageBlurFilter(Generic pparent)
contructor


REB_AverageBlurFilter

public REB_AverageBlurFilter()