[Insight-users] Code integration and code design - Question
Matt McCormick
matt.mccormick at kitware.com
Mon Nov 12 10:56:42 EST 2012
Hi Stephane,
Thanks for making contributions to the ITK community.
Regarding how to contribute new code, unless it is modifications to
existing classes, the preferred method is the creation of
External/Remote modules as described here:
http://insightsoftwareconsortium.github.com/ITKBarCamp-doc/ITK/ConstructITKModule/index.html
http://www.itk.org/Wiki/ITK/Policy_and_Procedures_for_Adding_Remote_Modules
This is preferred as opposed to forking the main repository for a
number of reasons.
Regarding the third party library usage: the general process is to
create a new Module for each third party library. If the library is
very small, it may be worthwhile to re-write it in ITK style instead.
> * Our code file contain several small inline function that are all in one .cxx file.
> 1 - Can we keep all the function into one file? Is there already
one such file in ITK that already >gather small inline function?
> 2 - Keep the aspect of 1 file = 1 class, and do one class for each small function in our code?
ITK uses an C++ object-orientated design, so re-factoring to be
consistent with ITK style may be necessary.
HTH,
Matt
On Mon, Nov 12, 2012 at 8:56 AM, Steffan <ulysse.rigaud at gmail.com> wrote:
> Hi everybody,
>
> We have an insight journal (http://hdl.handle.net/10380/3329) that we would
> like to integrate into ITK, and we are currently starting to merge them into
> our fork version of ITK to test.
> We have two questions, concerning the integration into the different module
> of ITK and on code design in ITK
>
> * To test the orientation of vectors, we are using a library in C that we
> have wrap into some ITK function. This library is a single file, done by
> Jonathan Shewchuk (http://www.cs.cmu.edu/~quake/robust.html) under public
> domain.
> Where should we integrate this library in ITK?
> 1 - In ThirdParty folder? As it is a third party library, external to ITK,
> and not in C++. CONS: it may be too much for only 1 file.
> 2 - Directly in Core/Mesh | Core/QuadEdgeMesh? This library is only on
> file and is use for geometrical exact orientation product mainly to be used
> into Mesh or QuadEdgeMesh filters. CONS: it is not an ITK/C++ files.
> 3 - Or we could integrate all the library into our wrappers class and then
> integrate our class into ITK (Mesh or QuadEdgeMesh folder for the reason
> explained in 2).
>
> * Our code file contain several small inline function that are all in one
> .cxx file.
> 1 - Can we keep all the function into one file? Is there already one such
> file in ITK that already gather small inline function?
> 2 - Keep the aspect of 1 file = 1 class, and do one class for each small
> function in our code?
>
> I hope my questions are clear enough.
>
> Thanks.
> Regards,
> --
> Stephane
>
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users
>
More information about the Insight-users
mailing list