<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p style="margin-top:0;margin-bottom:0">Hi Jorge,</p>
<p style="margin-top:0;margin-bottom:0">Thanks for your reply.</p>
<p style="margin-top:0;margin-bottom:0">I could do the ThresholdBetween to get the points.</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">I have another question.</p>
<p style="margin-top:0;margin-bottom:0">Is it possible for me to get the threshold value automatically without pre-assign the value to vtkThreshold?</p>
<p style="margin-top:0;margin-bottom:0">Let me explain further. I am doing a feature extraction using meanCurvature on the 3D vtk polydata. I obtained the meanCurvature values from the dataset. </p>
<p style="margin-top:0;margin-bottom:0">And I realized that threshold value (eg. ThresholdByUpper =0.085) could show the relevant regions (about 500-800 polydata points) that I am looking for.</p>
<p style="margin-top:0;margin-bottom:0">Now I want to obtain the threshold values automatically by looking into the points that </p>
<p style="margin-top:0;margin-bottom:0">If 500 points more than 0.085</p>
<p style="margin-top:0;margin-bottom:0">>>show me the threshold value</p>
<p style="margin-top:0;margin-bottom:0">If 600 points more than 0.085</p>
<p style="margin-top:0;margin-bottom:0">>>show me the threshold value</p>
I want to reverse the process to get the threshold values.
<div><br>
</div>
<div>Thanks again.</div>
<div><br>
</div>
<div>Best, </div>
<div>Polly<br>
<br>
<div style="color: rgb(0, 0, 0);">
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Jorge Perez <josp.jorge@gmail.com><br>
<b>Sent:</b> Wednesday, March 21, 2018 3:26 PM<br>
<b>To:</b> Polly Pui<br>
<b>Cc:</b> vtkusers@vtk.org<br>
<b>Subject:</b> Re: [vtkusers] vtkThreshold</font>
<div> </div>
</div>
<div>
<div dir="ltr">Hello, you can use <span style="color:rgb(37,53,85); font-family:arial,sans-serif; font-size:14px; font-style:normal; font-weight:700; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; background-color:rgb(226,232,242); float:none; display:inline">ThresholdBetween</span>
<div><br>
</div>
<div>
<div class="x_gmail-memproto" style="font-style:normal; font-variant:normal; font-weight:bold; font-size:14px; line-height:22px; font-family:Roboto,sans-serif; border-top:1px solid rgb(168,184,217); border-left:1px solid rgb(168,184,217); border-right:1px solid rgb(168,184,217); padding:6px 0px; color:rgb(37,53,85); background-image:url("nav_f.png"); background-repeat:repeat-x; background-color:rgb(226,232,242); border-top-right-radius:4px; border-top-left-radius:4px; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px">
<table class="x_gmail-memname" style="font-style:normal; font-variant:normal; font-weight:bold; font-size:14px; line-height:22px; font-family:Roboto,sans-serif; margin-left:6px">
<tbody>
<tr>
<td class="x_gmail-memname" style="font-weight:bold; margin-left:6px; vertical-align:bottom">
void vtkThreshold::ThresholdBetween</td>
<td style="vertical-align:bottom">(</td>
<td class="x_gmail-paramtype" style="white-space:nowrap; vertical-align:bottom"><a class="x_el" href="https://www.vtk.org/doc/nightly/html/vtkVectorOperators_8h.html#a45c855d65dd0e2b57b08024500ff9159" style="color:rgb(70,101,162); font-weight:bold; text-decoration:none" id="LPlnk211166" previewremoved="true">double</a> </td>
<td class="x_gmail-paramname" style="color:rgb(96,32,32); white-space:nowrap; vertical-align:bottom">
<em style="font-style:normal">lower</em>,</td>
</tr>
<tr>
<td class="x_gmail-paramkey" style="text-align:right; vertical-align:bottom"></td>
<td style="vertical-align:bottom"></td>
<td class="x_gmail-paramtype" style="white-space:nowrap; vertical-align:bottom"><a class="x_el" href="https://www.vtk.org/doc/nightly/html/vtkVectorOperators_8h.html#a45c855d65dd0e2b57b08024500ff9159" style="color:rgb(70,101,162); font-weight:bold; text-decoration:none" id="LPlnk695846" previewremoved="true">double</a> </td>
<td class="x_gmail-paramname" style="color:rgb(96,32,32); white-space:nowrap; vertical-align:bottom">
<em style="font-style:normal">upper</em> </td>
</tr>
<tr>
<td style="vertical-align:bottom"></td>
<td style="vertical-align:bottom">)</td>
<td style="vertical-align:bottom"></td>
<td style="vertical-align:bottom"></td>
</tr>
</tbody>
</table>
</div>
<div class="x_gmail-memdoc" style="font-style:normal; font-variant:normal; font-weight:400; font-size:14px; line-height:22px; font-family:Roboto,sans-serif; border-width:0px 1px 1px; border-bottom-style:solid; border-bottom-color:rgb(168,184,217); border-left-style:solid; border-left-color:rgb(168,184,217); border-right-style:solid; border-right-color:rgb(168,184,217); padding:6px 10px 2px; background-image:url("nav_g.png"); background-repeat:repeat-x; background-color:rgb(255,255,255); border-bottom-left-radius:4px; border-bottom-right-radius:4px; color:rgb(0,0,0); letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px">
<p style="font-style:normal; font-variant:normal; font-weight:400; font-size:14px; line-height:22px; font-family:Roboto,sans-serif">
Criterion is cells whose scalars are between lower and upper thresholds (inclusive of the end values).</p>
</div>
<br>
</div>
<div><a href="https://www.vtk.org/doc/nightly/html/classvtkThreshold.html#a20f1127a1da274eea9791c15410e9935" id="LPlnk437008" previewremoved="true">https://www.vtk.org/doc/nightly/html/classvtkThreshold.html#a20f1127a1da274eea9791c15410e9935</a><br>
</div>
</div>
<div class="x_gmail_extra"><br>
<div class="x_gmail_quote">2018-03-21 8:00 GMT+01:00 Polly Pui <span dir="ltr"><<a href="mailto:polly_sukting@hotmail.com" target="_blank" id="LPlnk790209" previewremoved="true">polly_sukting@hotmail.com</a>></span>:<br>
<blockquote class="x_gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div dir="ltr">
<div id="x_m_5621339414686821054divtagdefaultwrapper" dir="ltr" style="font-size:12pt; color:#000000; font-family:Calibri,Helvetica,sans-serif">
<p style="margin-top:0; margin-bottom:0">Hi,</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">Previously, I applied vtkThreshold with ThresholdByUpper and get the data extracted on 3D vtk dataset.</p>
<p style="margin-top:0; margin-bottom:0">For example, i could get 500 points out of 5000 points after the thresholding with a criterion of 0.085.</p>
<p style="margin-top:0; margin-bottom:0"></p>
<div>        vtkThreshold *thresh = vtkThreshold::New();</div>
<div><span style="white-space:pre-wrap"></span>thresh->SetInputConnection(<wbr>meanCurve->GetOutputPort());</div>
<div><span style="white-space:pre-wrap"></span>thresh->ThresholdByUpper(0.<wbr>085);</div>
<div><span style="white-space:pre-wrap"></span>thresh->AllScalarsOff();</div>
<div><span style="white-space:pre-wrap"></span>thresh->Update();</div>
<br>
<p></p>
<p style="margin-top:0; margin-bottom:0">Now, my question is, how i can do this process in an opposite way.</p>
<p style="margin-top:0; margin-bottom:0">I want to get the threshold value which the number of the points are within 500-600. </p>
<p style="margin-top:0; margin-bottom:0">Instead of I am the one who providing the threshold value manually.</p>
<p style="margin-top:0; margin-bottom:0">//</p>
<p style="margin-top:0; margin-bottom:0">If meanCurve points 500-600 provide threshold value</p>
<p style="margin-top:0; margin-bottom:0">If meanCurve points 600-700 provide threshold value</p>
<p style="margin-top:0; margin-bottom:0">...and so on</p>
<p style="margin-top:0; margin-bottom:0">//</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">Thanks.</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0">Best, </p>
<span class="x_HOEnZb"><font color="#888888">
<p style="margin-top:0; margin-bottom:0">Polly</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
<p style="margin-top:0; margin-bottom:0"><br>
</p>
</font></span></div>
</div>
<br>
______________________________<wbr>_________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank" id="LPlnk986709" previewremoved="true">
www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank" id="LPlnk764339" previewremoved="true">
http://www.kitware.com/<wbr>opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank" id="LPlnk411536" previewremoved="true">
http://www.vtk.org/Wiki/VTK_<wbr>FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank" id="LPlnk74860" previewremoved="true">
http://markmail.org/search/?q=<wbr>vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://vtk.org/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank" id="LPlnk682677" previewremoved="true">https://vtk.org/mailman/<wbr>listinfo/vtkusers</a><br>
<br>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
</div>
</body>
</html>