[vtkusers] Re : vtkusers Digest, Vol 64, Issue 2
Ben Salah Mohamed Selim
bsmstn at yahoo.fr
Wed Aug 5 10:58:25 EDT 2009
Hi,
When I process Points in Delaunay3D from a binary 3D matrix I have the
following message:
Generic Warning: In m:\dev\cur\vtkdotnet\branch\50\Common\vtkMath.cxx, line 394
Unable to factor linear system
Warning: In m:\dev\cur\vtkdotnet\branch\50\Graphics\vtkDelaunay3D.cxx, line 487
vtkDelaunay3D (0C767768): 7 degenerate triangles encountered, mesh quality suspect
Why ?
My code on C# looks like this :
LoadMatrix(innex);// to load the 3D binary matrix
int id=0;
vtk.vtkPoints points = new vtk.vtkPoints();
points.SetNumberOfPoints(Nbslice * NbColonne * Nbraw);
for (z = 0; z < Nbslice; z++)
{
for (y = 0; y < NbColonne; y++)
{
for (x = 0; x < Nbraw; x++)
{
if ((int)Canal3D[x, y, z] !=0)
{
points.InsertPoint(id, x, y, z);
id = id + 1;
}
}
}
}
vtk.vtkPolyData poly = new vtk.vtkPolyData();
poly.SetPoints(points);
vtk.vtkDelaunay3D del3D = new vtk.vtkDelaunay3D();
del3D.SetInput(poly);
del3D.SetTolerance(0.01);
del3D.SetAlpha(0.2);
del3D.BoundingTriangulationOff();
vtk.vtkShrinkFilter shrink = new vtk.vtkShrinkFilter();
shrink.SetInput(del3D.GetOutput());
shrink.SetShrinkFactor(0.9);
vtk.vtkDataSetMapper mapper = new vtk.vtkDataSetMapper();
mapper.SetInput(shrink.GetOutput());
vtk.vtkActor coneActor = new vtk.vtkActor();
coneActor.SetMapper(mapper);
vtk.vtkRenderer ren1 = new vtk.vtkRenderer();
ren1.AddActor(coneActor);
ren1.SetBackground(0.0f, 0.0f, 0.0f); renWin.AddRenderer(ren1);
--- En date de : Dim 2.8.09, vtkusers-request at vtk.org <vtkusers-request at vtk.org> a écrit :
De: vtkusers-request at vtk.org <vtkusers-request at vtk.org>
Objet: vtkusers Digest, Vol 64, Issue 2
À: vtkusers at vtk.org
Date: Dimanche 2 Août 2009, 18h00
Send vtkusers mailing list submissions to
vtkusers at vtk.org
To subscribe or unsubscribe via the World Wide Web, visit
http://www.vtk.org/mailman/listinfo/vtkusers
or, via email, send a message with subject or body 'help' to
vtkusers-request at vtk.org
You can reach the person managing the list at
vtkusers-owner at vtk.org
When replying, please edit your Subject line so it is more specific
than "Re: Contents of vtkusers digest..."
Today's Topics:
1. Re: [CMake] QT_QTCORE_LIBRARY_DEBUG-NOTFOUND (Dominik Szczerba)
2. Re: [Paraview] qvtk problems with the pipeline (Dominik Szczerba)
3. Re: [CMake] QT_QTCORE_LIBRARY_DEBUG-NOTFOUND (Dominik Szczerba)
----------------------------------------------------------------------
Message: 1
Date: Sat, 01 Aug 2009 19:42:33 +0200
From: Dominik Szczerba <dominik at itis.ethz.ch>
Subject: Re: [vtkusers] [CMake] QT_QTCORE_LIBRARY_DEBUG-NOTFOUND
To: Clinton Stimpson <clinton at elemtech.com>
Cc: VTK users group <vtkusers at vtk.org>, CMake mailing list
<cmake at cmake.org>
Message-ID: <4A747E89.9070007 at itis.ethz.ch>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Yes indeed, I was confused by Windows where one has separate libs e.g.
QtCore and QtCored. Still, I do not have any /usr/lib/libQt*debug files
(I DID install the qt-dbg pacgages) but the symbols are somehow there in
the debugger backtrace despite debug versions NOTFOUND. It's a quite
confusing. But many thanks for clarifications!
-- Dominik
Clinton Stimpson wrote:
> On 08/01/2009 01:28 AM, Dominik Szczerba wrote:
>> Hi,
>>
>> I want to build vtk with cmake using QT in debug mode on linux. I have
>> tried both installing the system QT debug symbols package (Ubuntu) as
>> well as compiling QT myself with (debug-and-release mode), but cmake
>> keeps displaying:
>>
>> QT_QTCORE_LIBRARY_DEBUG-NOTFOUND
>>
>> My CMAKE_BUILD_TYPE is DEBUG. How can I force the use of QT debug
>> version?
>>
>> - Dominik
>>
>
> Qt typically gives a .debug file for debug symbols. So that would be a
> libQtCore.so and libQtCore.so.debug instead of libQtCore.so and
> libQtCored.so. Its fine for QT_QTCORE_LIBRARY_DEBUG to be NOTFOUND, if
> you have a .debug file. Or if you configured Qt with -debug and it gave
> you a debug library with the name of a release library, you can ignore
> that QT_QTCORE_LIBRARY_DEBUG is NOTFOUND.
>
> Clint
>
>
--
d o m i n i k s z c z e r b a , p h d . . . . . . . . . . .
c o m p u t a t i o n a l l i f e s c i e n c e g r o u p
. . . . . . . i t ' i s r e s e a r c h f o u n d a t i o n
. . . . . . . . . . . . . . . . . . . . http://www.itis.ethz.ch
------------------------------
Message: 2
Date: Sat, 01 Aug 2009 19:52:45 +0200
From: Dominik Szczerba <dominik at itis.ethz.ch>
Subject: Re: [vtkusers] [Paraview] qvtk problems with the pipeline
To: Clinton Stimpson <clinton at elemtech.com>
Cc: VTK users group <vtkusers at vtk.org>, paraview at paraview.org
Message-ID: <4A7480ED.4050201 at itis.ethz.ch>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Clinton Stimpson wrote:
> On 08/01/2009 05:01 AM, Dominik Szczerba wrote:
>> Many thanks for the feedback. Pls see below:
>>
>> Clinton Stimpson wrote:
>>> Dominik Szczerba wrote:
>>>> My pipeline works all right and gets updated on demand properly. I
>>>> achieve it by connecting spinboxes/lineedits etc. to functions that
>>>> set parameters of my filters before I explicitly hit the final
>>>> 'apply' button. The annoying problem is that the pipeline gets
>>>> executed also when I interact with the render window (click to
>>>> rotate etc.). I did not (intend to) set up such functionality, I
>>>> want the pipeline to execute only after an explicit button click
>>>> (like in paraview). How do I find out who is triggering the pipeline
>>>> behind my back?
>>>>
>>>> - Dominik
>>>>
>>> ParaView queues up the changes, and only applies them to the filters
>>> when the apply button is pressed.
>>> If you're applying them on the filters when spinboxes/lineedits
>>> change, and a menu comes and goes over the graphics view, that could
>>> trigger an update you might not want.
>>>
>>> How about your apply button gathering the parameters from the widgets
>>> on the form and applying them?
>> That was my original idea and implementation: However, this way the
>> WHOLE pipeline ALWAYS gets re-executed. Concrete example pipeline:
>> extractVOI->GaussianSmooth. If Apply button gathers the parameters and
>> sets them to the filters every time, changing e.g. only smoothing
>> params (while keeping the same VOI) still causes both filters to
>> re-execute. This should not happen, as VOI should be up to date. The
>> same is true for more filters, e.g. Threshold: re-feeding the same
>> parameters and/or arrays to process somehow fools the up-to-date'ness
>> of the filter. Am I expected to walk around the problem by bookkeeping
>> the changing params and the up-to-date'ness myself?
>>
>> Note that this is different to paraview, where you have only one
>> filter per menu entry and can explicitly request changes. Here I have
>> one meta-filter, consisting of several atomic ones.
>>
>> After your remark I feel the original approach was the right one. But
>> then how do I only request the update if a REAL CHANGE and not only a
>> FORMAL SET of parameters is the case?
>>
>
> vtkSetMacro checks for changes before calling this->Modified(); But are
> you saying its a problem because not all Set functions check for changes?
I am saying that (e.g.) setting VOI in vtkExtractVOI or
InputArrayToProcess in vtkThreshold to the already previously set values
(no factual change, just re-feed of the old ones) triggers the pipeline
to re-execute. I do not understand this behavior as I was - as you point
out - hoping for the set macros to take care of that.
>
> To do your own bookkeeping, one idea is to connect to the QWidget's user
> property's notify signal (see QMetaObject::userPropery), and anytime one
> of those fires, you add to a list of widgets that have changed. Then at
> apply time, just push those values down.
>
A little above my knowledge level but many thanks for the pointers to
start with!
Overall, many thanks for valuable insights.
-- Dominik
> Clint
>
>
--
d o m i n i k s z c z e r b a , p h d . . . . . . . . . . .
c o m p u t a t i o n a l l i f e s c i e n c e g r o u p
. . . . . . . i t ' i s r e s e a r c h f o u n d a t i o n
. . . . . . . . . . . . . . . . . . . . http://www.itis.ethz.ch
------------------------------
Message: 3
Date: Sat, 01 Aug 2009 20:35:36 +0200
From: Dominik Szczerba <dominik at itis.ethz.ch>
Subject: Re: [vtkusers] [CMake] QT_QTCORE_LIBRARY_DEBUG-NOTFOUND
To: Pau Garcia i Quiles <pgquiles at elpauer.org>
Cc: VTK users group <vtkusers at vtk.org>, CMake mailing list
<cmake at cmake.org>, Clinton Stimpson <clinton at elemtech.com>
Message-ID: <4A748AF8.7040805 at itis.ethz.ch>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Many thanks, I did not know that... (But then again, how could I?) That
explains NOTFOUND, if a human user can not find it... But as posted
before, accepting NOTFOUND with no action like
-DQT_QTCORE_LIBRARY_DEBUG=/usr/lib/libQtCore.so.4.5.0 I still get the
debugging symbols in the backtrace. I have no *.debug files mentioned
before... I do not like this because it leaves me uncertain if I am
doing the right thing or confusing the debugger (and yes, at the moment
my backtrace is rather enigmatic). I will probably compile QT myself and
recompile my VTK build to have a bigger control.
Many thanks for valuable remarks,
Dominik
Pau Garcia i Quiles wrote:
> Hello,
>
> Check /usr/lib/debug/usr/lib
>
> On Sat, Aug 1, 2009 at 7:42 PM, Dominik Szczerba<dominik at itis.ethz.ch> wrote:
>> Yes indeed, I was confused by Windows where one has separate libs e.g.
>> QtCore and QtCored. Still, I do not have any /usr/lib/libQt*debug files (I
>> DID install the qt-dbg pacgages) but the symbols are somehow there in the
>> debugger backtrace despite debug versions NOTFOUND. It's a quite confusing.
>> But many thanks for clarifications!
>> -- Dominik
>>
>> Clinton Stimpson wrote:
>>> On 08/01/2009 01:28 AM, Dominik Szczerba wrote:
>>>> Hi,
>>>>
>>>> I want to build vtk with cmake using QT in debug mode on linux. I have
>>>> tried both installing the system QT debug symbols package (Ubuntu) as well
>>>> as compiling QT myself with (debug-and-release mode), but cmake keeps
>>>> displaying:
>>>>
>>>> QT_QTCORE_LIBRARY_DEBUG-NOTFOUND
>>>>
>>>> My CMAKE_BUILD_TYPE is DEBUG. How can I force the use of QT debug
>>>> version?
>>>>
>>>> - Dominik
>>>>
>>> Qt typically gives a .debug file for debug symbols. So that would be a
>>> libQtCore.so and libQtCore.so.debug instead of libQtCore.so and
>>> libQtCored.so. Its fine for QT_QTCORE_LIBRARY_DEBUG to be NOTFOUND, if you
>>> have a .debug file. Or if you configured Qt with -debug and it gave you a
>>> debug library with the name of a release library, you can ignore that
>>> QT_QTCORE_LIBRARY_DEBUG is NOTFOUND.
>>>
>>> Clint
>>>
>>>
>>
>> --
>> d o m i n i k s z c z e r b a , p h d . . . . . . . . . . .
>> c o m p u t a t i o n a l l i f e s c i e n c e g r o u p
>> . . . . . . . i t ' i s r e s e a r c h f o u n d a t i o n
>> . . . . . . . . . . . . . . . . . . . . http://www.itis.ethz.ch
>>
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the CMake FAQ at:
>> http://www.cmake.org/Wiki/CMake_FAQ
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.cmake.org/mailman/listinfo/cmake
>>
>
>
>
--
d o m i n i k s z c z e r b a , p h d . . . . . . . . . . .
c o m p u t a t i o n a l l i f e s c i e n c e g r o u p
. . . . . . . i t ' i s r e s e a r c h f o u n d a t i o n
. . . . . . . . . . . . . . . . . . . . http://www.itis.ethz.ch
------------------------------
_______________________________________________
vtkusers mailing list
vtkusers at vtk.org
http://www.vtk.org/mailman/listinfo/vtkusers
End of vtkusers Digest, Vol 64, Issue 2
***************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090805/3ba298a0/attachment.htm>
More information about the vtkusers
mailing list