[Insight-developers] about problems in itkFilterMeshToMesh
    Ting Chen 
    chenting@graphics.cis.upenn.edu
    Wed, 10 Jan 2001 14:48:50 -0600
    
    
  
This is a multi-part message in MIME format.
------=_NextPart_000_001F_01C07B14.718BE5D0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
as you asked I attached the header file and part of the cxx file, I hope
this would be helpful.
Thanks!
I will read those test files and retry to include the matrix object.
------=_NextPart_000_001F_01C07B14.718BE5D0
Content-Type: application/octet-stream;
	name="itkFilterBalloonForceTest.h"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="itkFilterBalloonForceTest.h"
/*=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
  Program:   Insight Segmentation & Registration Toolkit
  Copyright (c) 2000 National Library of Medicine
  All rights reserved.
  See COPYRIGHT.txt for copyright details.
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D*/
#ifndef __itkFilterBalloonForceTest_h
#define __itkFilterBalloonForceTest_h
#include "itkFilterMeshToMesh.h"
namespace itk
{
/** \class FilterMeshToMesh
 * \brief=20
 *
 * FilterMeshToMesh is the base class for all process objects that =
output
 * mesh data, and require mesh data as input. Specifically, this class
 * defines the SetInput() method for defining the input to a filter.
 */
template <class TInputMesh, class TOutputMesh>
class ITK_EXPORT FilterBalloonForceTest : public =
FilterMeshToMesh<TInputMesh, TOutputMesh>
{
public:
  /**
   * Standard "Self" typedef.
   */
  typedef FilterBalloonForceTest  Self;
  /**
   * Standard "Superclass" typedef.
   */
  typedef FilterMeshToMesh<TInputMesh, TOutputMesh> Superclass;
  /**=20
   * Smart pointer typedef support=20
   */
  typedef SmartPointer<Self>  Pointer;
  /**
   * Method for creation through the object factory.
   */
  itkNewMacro(Self);
 =20
  /**=20
   * Run-time type information (and related methods).
   */
  itkTypeMacro(FilterBalloonForceTest,FilterMeshToMesh);
  /**=20
   * Some typedefs.
   */
  typedef TInputMesh InputMeshType;
  typedef typename InputMeshType::Pointer InputMeshPointer;
  /**=20
   * Set the mesh input of this process object.=20
   */
//  void SetInput(InputMeshType *input);
  /**=20
   * Get the mesh input of this process object.=20
   */
//  InputMeshPointer GetInput();
//  InputMeshPointer GetInput(unsigned int idx);
  void ComputeForce();
  void Initialize();
  void SetStiffnessMatrix();
  void Advance();
protected:
  FilterBalloonForceTest();
  ~FilterBalloonForceTest() {};
  FilterBalloonForceTest(const FilterBalloonForceTest&) {};
  void operator=3D(const FilterBalloonForceTest&) {};
  void PrintSelf(std::ostream& os, Indent indent);
  InputMeshPointer Forces;=20
  InputMeshPointer Normals;
  InputMeshPointer Displacements;
  double NStiffness[4][4];
  double SStiffness[4][4];
  double CStiffness[4][4];
 =20
  double Stiffness[2];
  double Timestep;
//  itk::image<unsigned char> Potential;
  double*** K;
 =20
};
} // end namespace itk
#ifndef ITK_MANUAL_INSTANTIATION
#include "itkFilterMeshToMesh.txx"
#endif
#endif
------=_NextPart_000_001F_01C07B14.718BE5D0
Content-Type: text/plain;
	name="file2.txt"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
	filename="file2.txt"
//just part of it, the part I did not post is some user-defined =
functions and=20
//should have no relation with the problem.
#include "itkFilterBalloonForceTest.h"
//typedef itk::Mesh<int>  Mesh;
namespace itk
{
 =20
/**
 *
 */
template <class TInputMesh, class TOutputMesh>
FilterBalloonForceTest<TInputMesh,TOutputMesh>
::FilterBalloonForceTest()
{
  // Modify superclass default values, can be overridden by subclasses
  this->SetNumberOfRequiredInputs(1);
}
/**
 *
 */
/*
template <class TInputMesh, class TOutputMesh>
void=20
FilterBalloonForceTest<TInputMesh,TOutputMesh>
::SetInput(TInputMesh *input)
{
  this->ProcessObject::SetNthInput(0, input);
}
/**
 *
 */
/*
template <class TInputMesh, class TOutputMesh>
FilterBalloonForceTest<TInputMesh,TOutputMesh>::InputMeshPointer
FilterBalloonForceTest<TInputMesh,TOutputMesh>
::GetInput()
{
  if (this->NumberOfInputs < 1)
    {
    return 0;
    }
 =20
  return static_cast<TInputMesh*>
                     (this->ProcessObject::GetInput(0).GetPointer());
}
 =20
/**
 *
 */
/*
template <class TInputMesh, class TOutputMesh>
FilterBalloonForceTest<TInputMesh,TOutputMesh>::InputMeshPointer
FilterBalloonForceTest<TInputMesh,TOutputMesh>
::GetInput(unsigned int idx)
{
  return static_cast<TInputMesh*>
                     (this->ProcessObject::GetInput(idx).GetPointer());
}
/**
 *
 */
template <class TInputMesh, class TOutputMesh>
void=20
FilterBalloonForceTest<TInputMesh,TOutputMesh>
::PrintSelf(std::ostream& os, Indent indent)
{
  Superclass::PrintSelf(os,indent);
}
}
------=_NextPart_000_001F_01C07B14.718BE5D0--