adding new objects and building vtk
Jon Klingensmith
klingej at bme.ri.ccf.org
Mon Feb 21 11:32:15 EST 2000
Hello Damini,
Do I have to put the source in a specific directory? If I put the .cxx and .h file
in my vtkSource/contrib directory (D:/vtkSource/contrib/vtkMyClass.cxx and
D:/vtkSource/contrib/vtkMyClass.h) then do I have to specify that in Makefile.in ??
I listed the class like you suggested and ran pcmaker again, but it doesn't seem to
do anything to the makefiles generate.
Thanks for your help,
Jon
Damini Dey wrote:
> Hi Jon,
>
> Say you have a class vtkMyClass.cxx and vtkMyClass.h
> Based on whether the class is abstract or concrete, you add it like this:
>
> EITHER under
>
> ABSTRACT = \
> vtkMyClass
>
> OR under
>
> CONCRETE = \
> vtkMyClass
>
> The ABSTRACT_H or CONCRETE_H places are for classes that are defined by .h files
> only
> (eg vtkActorCollection.h)
>
> Damini.
>
> > My makefile.in looks like this.. would I just add the .h file after CONCRETE_H
> > and the .cxx file after CONCRETE if its a concrete object?
> >
> > Thanks,
> > Jon
> >
> > #
> > # vtk library makefile
> > #
> > # NOTE !!! when adding a class, it must be added in one location.
> > # Place it in the correct list based on whether it is only a .h file
> > # and whether it is abstract or concrete.
> > #
> > ME = Local
> >
> > srcdir = @srcdir@
> > VPATH = @srcdir@
> >
> > ABSTRACT_H =
> >
> > CONCRETE_H =
> >
> > ABSTRACT =
> >
> > CONCRETE =\
> >
> > #------------------------------------------------------------------------------
> >
> > # Autoconfig defines that can be overridden in user.make
> >
> > @MAKEINCLUDE@ @MAKEQUOTE at ../system.make at MAKEQUOTE@
> >
> > #------------------------------------------------------------------------------
> >
> > # Include user-editable defines.
> >
> > @MAKEINCLUDE@ @MAKEQUOTE at ../user.make at MAKEQUOTE@
> >
> > #------------------------------------------------------------------------------
> >
> > # Include the generated targets
> >
> > @MAKEINCLUDE@ @MAKEQUOTE at targets.make@MAKEQUOTE@
> >
> > # add in any extra libraies here
> > KIT_LIBS =
> >
> > # standard stuff here
> > KIT_OBJ = ${SRC_OBJ}
> > KIT_TCL_OBJ = ${TCL_OBJ}
> > KIT_NEWS = ${TCL_NEWS}
> > KIT_FLAGS =
> > PYTHON_LIBS = -L../graphics -lVTKGraphicsPython -L../imaging -lVTKImagingPython
> > -L../common -lVTKCommonPython ${XLIBS} ${GRAPHICS_API_LIBS}
> >
> > VTK_LIB_FILE = libVTK${ME}${VTK_LIB_EXT}
> > TCL_LIB_FILE = libVTK${ME}Tcl${VTK_LIB_EXT}
> >
> > #------------------------------------------------------------------------------
> >
> > # Include the generic stuff here
> >
> > @MAKEINCLUDE@ @MAKEQUOTE@@srcdir@/../Kits.make at MAKEQUOTE@
> >
> > Damini Dey wrote:
> >
> > > Hi Jon,
> > >
> > > You have to manually edit the makefile.in in only one place, in
> > > /vtk/local directory
> > > (/vtk/contrib for vtk2.4 or lower version). Then run the pcmaker, and nmake
> > > in the /vtkbin directory
> > >
> > > Damini.
> > >
> > > > I am trying to learn how to add new objects to vtk for my own use. I
> > > > have built vtk on NT using the tcl wrappers. If I add my own class
> > > > (vtkClass.h and vtkClass.cxx), do I have to manually edit the makefiles
> > > > in my
> > > > vtkBin directory to add this new object? Is there a way to have pcmaker
> > > > add
> > > > the new object to the makefiles it generates?
> > > >
> > > > I would appreciate any advice on how to do this or caveats involved.
> > > >
> > > > Thanks,
> > > > Jon
> >
--------------------------------------------------------------------
This is the private VTK discussion list. Please keep messages on-topic.
Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at public.kitware.com>. For help, send message body containing
"info vtkusers" to the same address.
--------------------------------------------------------------------
More information about the vtkusers
mailing list