Hello Sascha,

thanks for helping with this

I sent you two testing meshes already and here's my code:

// given some filter that generates the unstructured grid (i saved
unstructuredGrid to file and can load it with paraview)

   mitk::UnstructuredGrid::Pointer unstructuredGrid = filter->GetOutput();
    unstructuredGrid->DisconnectPipeline();

    m_UnstructuredGridNode = mitk::DataTreeNode::New();
    m_UnstructuredGridNode->SetData(unstructuredGrid);
    mitk::CoreExtObjectFactory::GetInstance()->SetDefaultProperties(
m_UnstructuredGridNode );
    m_UnstructuredGridNode->SetName("Tetra Mesh");
    // this enables cuts through the unstructured grid to be visible in 2D views
    m_UnstructuredGridNode->SetProperty("outline polygons",
mitk::BoolProperty::New(true));

   if ( !this->GetDefaultDataStorage()->Exists( m_UnstructuredGridNode ) )
        this->GetDefaultDataStorage()->Add(m_UnstructuredGridNode);

that´s it!

thank you,
sebastian


On Thu, Feb 11, 2010 at 8:52 PM, Sascha Zelzer
<[email protected]> wrote:
> Hi Sebastian,
>
> sorry, for the long wait. Other things have been on my radar recently, but I
> just took some time to look into the problem. It turns out that I could load
> a .vtk file (with the ExtApp) containing an unstructured grid without any
> problems with a svn checkout from yesterday.
>
> What exactly are you trying to do? Do you have troubles adding a vtk
> unstructured grid to the DataStorage within your code?
>
> Best,
> Sascha
>
> On 02/11/2010 11:34 PM, sebastian ordas wrote:
>>
>> Hello Sacha,
>>
>> Did you have the chance of rendering an unstructured grid?
>>
>> Let me know if so
>>
>> than you,
>> sebastian
>>
>> Mon, 12 Oct 2009 10:01:34 -0700
>>
>> Hi Sebastian,
>>
>> I'm afraid that the unstructured grid support was lost somewhere during
>> the
>> redesign phase of the MITK rendering system. I did not try to visualize an
>> unstructured grid for some time, but I will need this feature myself soon,
>> so I
>> will keep you posted about the state of the unstructured grid mappers.
>>
>> Cheers,
>> Sascha
>>
>>
>> -----Ursprüngliche Nachricht-----
>> Von: sebastian ordas [mailto:[email protected]]
>> Gesendet: Montag, 12. Oktober 2009 18:16
>> An: [email protected]
>> Cc: Zelzer Sascha
>> Betreff: cannot render a mitkUnstructuredGrid
>>
>> Hi All,
>>
>> Regarding the following discussion topic:
>> http://www.mail-archive.com/[email protected]/msg00296.html
>> I did also tried opening a vtkUnstructuredGrid and found trouble
>> rendering it.
>>
>> Furthermore, I generated my own mitk::UnstructuredGrid as suggested in
>> the post but could not add it to the DataStorage.
>>
>> Sasha, is that working for you in the new MITK-OpenCherry application?
>>
>> cheers,
>> sebastian
>>
>> PS: using SVN mitk
>>
>
>

------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
mitk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to