From afce2a3d72f559d0d8c58f54bc9425f2aebf457f Mon Sep 17 00:00:00 2001 From: davila Date: Thu, 13 Mar 2014 14:03:34 +0100 Subject: [PATCH] 2338 BBTK Bug New Normal UnaryOperation error divide / multiply --- packages/vtk/src/bbvtkUnaryOperations.cxx | 24 +++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/vtk/src/bbvtkUnaryOperations.cxx b/packages/vtk/src/bbvtkUnaryOperations.cxx index dd9b65a..d6e9601 100644 --- a/packages/vtk/src/bbvtkUnaryOperations.cxx +++ b/packages/vtk/src/bbvtkUnaryOperations.cxx @@ -57,8 +57,8 @@ void UnaryOperations::Process() ope->SetInput1((vtkDataObject*)bbGetInputIn1()); - ope->SetConstantK(bbGetInputInConstant()); - ope->SetConstantC(bbGetInputInConstant()); + ope->SetConstantK( bbGetInputInConstant() ); +// ope->SetConstantC(bbGetInputInConstant()); switch (bbGetInputOperation()) { @@ -67,25 +67,22 @@ void UnaryOperations::Process() break; case 1: -//EED Borrame crearPredeterminado(); - ope->SetInput2((vtkDataSet*) constante); - ope->SetOperationToSubtract(); + ope->SetConstantK( -1.0 * bbGetInputInConstant() ); + ope->SetOperationToAddConstant(); break; case 2: - ope->SetInput2((vtkDataSet*) constante); - ope->SetOperationToMultiply(); + ope->SetOperationToMultiplyByK(); +printf("EED UnaryOperations::Process() 2 \n"); break; case 3: - - ope->SetOperationToDivide(); + ope->SetConstantK( 1.0/bbGetInputInConstant() ); + ope->SetOperationToMultiplyByK(); +printf("EED UnaryOperations::Process() 3 \n"); break; case 4: ope->SetOperationToInvert(); break; - case 9: - ope->SetOperationToAbsoluteValue(); - break; case 5: ope->SetOperationToSin(); @@ -103,6 +100,9 @@ void UnaryOperations::Process() ope->SetOperationToLog(); break; + case 9: + ope->SetOperationToAbsoluteValue(); + break; /* EED 21Juin 2011 Borrame -- 2.47.1