Hi,
thanks for your response. Unfortunately, setting the spacing also
results in the same problem. But now I found a solution :-)
After setting transformation-matrix/spacing I call now
mitk::RenderingManager::GetInstance()->InitializeViews(mitk::DataStorage::GetInstance());
which reinitialize the views. That solves the problem.
Milad
Neuhaus Jochen wrote:
> Hi,
>
> If you only want to scale the image, you could try to re-set the spacing:
>
> float doubleSize[] = {2.0, 2.0, 2.0};
> "dataTreeNode"->GetData()->GetGeometry()->SetSpacing(doubleSize);
>
> Hope that helps,
> Jochen
>
>
>> -----Ursprüngliche Nachricht-----
>> Von: Milad Sadinam [mailto:[email protected]]
>> Gesendet: Montag, 6. Juli 2009 15:15
>> An: [email protected]
>> Betreff: [mitk-users] Scalation of mitk::Image-objects
>>
>> Dear mitk-developers,
>>
>> I come with another problem. I try to scale a mitk::image-object (3d
>> slice-picture) in the z-direction. To do so, I set a
>> transformation-matrix using the following code:
>>
>> "dataTreeNode"->GetData()->GetGeometry()->
>>
>> SetIndexToWorldTransformByVtkMatrix("vtkTransform-object"-
>>
>>> GetMatrix());
>>>
>> "dataTreeNode"->Modified();
>>
>>
>> The image gets scaled but unfortunately the 2d-view does not adjust its
>> size. So, when I enlarge the image only part of it is then visible in
>> the 2d-views.
>> I tried to somehow update the view-size of the 2d-view but without any
>> success.
>> Anybody an idea?
>>
>> Thanks,
>> Milad
>>
>> -----------------------------------------------------------------------
>> -------
>> _______________________________________________
>> mitk-users mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/mitk-users
>>
>
>
------------------------------------------------------------------------------
_______________________________________________
mitk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mitk-users