From: Esteban Correa Date: Wed, 9 Jan 2013 16:36:23 +0000 (+0100) Subject: Set image origin to {0.0,0.0,0.0} in imageChangeInformation Box X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=fd5809bcc472277366296dec8e2cf13ef0fd970c;p=creaMaracasVisu.git Set image origin to {0.0,0.0,0.0} in imageChangeInformation Box --- diff --git a/bbtk/src/bbmaracasvisuImageChangeInformation.cxx b/bbtk/src/bbmaracasvisuImageChangeInformation.cxx index 9adbae8..de4e0fc 100644 --- a/bbtk/src/bbmaracasvisuImageChangeInformation.cxx +++ b/bbtk/src/bbmaracasvisuImageChangeInformation.cxx @@ -40,7 +40,15 @@ void ImageChangeInformation::Process() mchange->Delete(); } mchange = vtkImageChangeInformation::New(); - img->GetExtent( ext ); + img->GetExtent( ext ); + + double origin[3]; + origin[0]=0.0; + origin[1]=0.0; + origin[2]=0.0; + + img->SetOrigin(origin); + mchange->SetInput( img ); mchange->SetExtentTranslation( -ext[0], -ext[2], -ext[4] ); mchange->SetOutputOrigin (0, 0, 0);