30 #if defined(DrawWithDisplay3DModifier_RECURSES)
31 #error Recursive header files inclusion detected in DrawWithDisplay3DModifier.h
34 #define DrawWithDisplay3DModifier_RECURSES
36 #if !defined DrawWithDisplay3DModifier_h
38 #define DrawWithDisplay3DModifier_h
43 #include "DGtal/base/Common.h"
44 #include "DGtal/helpers/StdDefs.h"
45 #include "DGtal/base/Alias.h"
46 #include "DGtal/base/ConstAlias.h"
47 #include "DGtal/images/CConstImage.h"
48 #include "DGtal/base/CountedPtr.h"
49 #include "DGtal/topology/KhalimskySpaceND.h"
80 SetMode3D( std::string classname, std::string mode )
141 const Color & fillColor )
161 ClippingPlane(
double a,
double b,
double c,
double d,
bool drawPlane=
true )
204 double aShift=0.05,
double aSizeFactor=0.75 )
207 auto const& preSurfel = aSurfel.
preCell();
208 auto const& preVoxel = aVoxel.
preCell();
210 bool xodd = (preSurfel.coordinates[ 0 ] & 1 );
211 bool yodd = (preSurfel.coordinates[ 1 ] & 1 );
212 bool zodd = (preSurfel.coordinates[ 2 ] & 1 );
215 myShift*= ((preVoxel.coordinates[ 0 ]-preSurfel.coordinates[ 0 ] <0)? -1.0: 1.0);
218 myShift*=((preVoxel.coordinates[ 1 ]-preSurfel.coordinates[ 1 ] <0)? -1.0: 1.0);
221 myShift*=((preVoxel.coordinates[ 2 ]-preSurfel.coordinates[ 2 ] <0)? -1.0: 1.0);
268 std::string
className()
const {
return "SetSelectCallback3D"; }
280 #include "DGtal/io/DrawWithDisplay3DModifier.ih"
288 #undef DrawWithDisplay3DModifier_RECURSES
Structure representing an RGB triple with alpha component.
DGtal is the top-level namespace which contains all DGtal functions and types.
boost::int32_t int32_t
signed 32-bit integer.
Class for adding a Clipping plane through the Viewer3D stream. Realizes the concept CDrawableWithView...
ClippingPlane(double a, double b, double c, double d, bool drawPlane=true)
CustomColors3D(const Color &penColor, const Color &fillColor)
Modifier class in a Display3D stream. Useful to choose your own style for a given class....
std::string className() const
CountedPtr< DrawableWithDisplay3D > myStyle
CustomStyle3D(std::string aClassname, DrawableWithDisplay3D *style)
Base class specifying the methods for classes which intend to modify a Viewer3D stream.
std::string className() const
Modifier class in a Display3D stream. Useful to choose your own mode for a given class....
SetMode3D(std::string classname, std::string mode)
DGtal::int32_t name
the "OpenGL name" for selection, or -1 for none.
SetName3D(DGtal::int32_t aName=-1)
std::string className() const
SetSelectCallback3D(CallbackFct f, void *data, DGtal::int32_t min=0, DGtal::int32_t max=0x7fffffff)
CallbackFct myFct
The callback function associated to the selection of an element.
std::string className() const
int(* CallbackFct)(void *viewer, DGtal::int32_t name, void *data)
Represents a signed cell in a cellular grid space by its Khalimsky coordinates and a boolean value.
SPreCell const & preCell() const
Returns the underlying constant signed pre-cell.