Skip to content

Commit

Permalink
Refs #7091. Change threshold parameter to double.
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Reuter committed May 29, 2013
1 parent 43f31c1 commit 93cde90
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,16 @@
number_of_elements="1"
default_values="150000">
</IntVectorProperty>
<IntVectorProperty
<DoubleVectorProperty
name="Top Percentile"
command="SetTopPercentile"
number_of_elements="1"
default_values="5">
<IntRangeDomain name="range" min="1" max="100" />
<DoubleRangeDomain name="range" min="0.1" max="100" />
<Documentation>
The set the viewing limit to the top percentile of the denses boxes.
</Documentation>
</IntVectorProperty>
</DoubleVectorProperty>
</SourceProxy>
</ProxyGroup>
<!-- End SplatterPlot -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ void vtkSplatterPlot::SetNumberOfPoints(int nPoints)
* Set the threshold for the top percentile of most dense boxes to view
* @param topPercentile : the limit on the percentile of boxes to show
*/
void vtkSplatterPlot::SetTopPercentile(int topPercentile)
void vtkSplatterPlot::SetTopPercentile(double topPercentile)
{
if (topPercentile > 0)
{
Expand Down Expand Up @@ -81,7 +81,7 @@ int vtkSplatterPlot::RequestData(vtkInformation *, vtkInformationVector **, vtkI

std::string scalarName = "signal";
vtkSplatterPlotFactory vtkGridFactory(ThresholdRange_scptr(new NoThresholdRange), scalarName, m_numberPoints,
static_cast<double>(m_topPercentile));
m_topPercentile);
vtkGridFactory.initialize(result);

FilterUpdateProgressAction<vtkSplatterPlot> drawUpdateProgress(this, "Drawing...");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ class VTK_EXPORT vtkSplatterPlot : public vtkUnstructuredGridAlgorithm
vtkTypeMacro(vtkSplatterPlot, vtkUnstructuredGridAlgorithm);
void PrintSelf(ostream& os, vtkIndent indent);
void SetNumberOfPoints(int nPoints);
void SetTopPercentile(int topPercentile);
void SetTopPercentile(double topPercentile);
void updateAlgorithmProgress(double progress, const std::string& message);
protected:

Expand All @@ -22,6 +22,6 @@ class VTK_EXPORT vtkSplatterPlot : public vtkUnstructuredGridAlgorithm
vtkSplatterPlot(const vtkSplatterPlot&);
void operator = (const vtkSplatterPlot&);
size_t m_numberPoints;
int m_topPercentile;
double m_topPercentile;
};
#endif

0 comments on commit 93cde90

Please sign in to comment.