// Copyright (C) 2002-2003 Gideon May (gideon@computer.org) // // Permission to copy, use, sell and distribute this software is granted // provided this copyright notice appears in all copies. // Permission to modify the code and to distribute modified code is granted // provided this copyright notice appears in all copies, and a notice // that the code was modified is included with the copyright notice. // // This software is provided "as is" without express or implied warranty, // and with no claim as to its suitability for any purpose. #include #include #include #include using namespace boost::python; namespace PyOSG { void init_CopyOp() { class_ copy_op("CopyOp"); copy_op .def(init()) ; scope copy_op_scope(copy_op); # define OSG_ENUM_OPTIONS(VALUE) \ (options.value(#VALUE, osg::CopyOp::VALUE), \ copy_op.def(#VALUE, copy_op(osg::CopyOp::VALUE))) enum_ options("Options"); OSG_ENUM_OPTIONS(SHALLOW_COPY); OSG_ENUM_OPTIONS(DEEP_COPY_OBJECTS); OSG_ENUM_OPTIONS(DEEP_COPY_NODES); OSG_ENUM_OPTIONS(DEEP_COPY_DRAWABLES); OSG_ENUM_OPTIONS(DEEP_COPY_STATESETS); OSG_ENUM_OPTIONS(DEEP_COPY_STATEATTRIBUTES); OSG_ENUM_OPTIONS(DEEP_COPY_TEXTURES); OSG_ENUM_OPTIONS(DEEP_COPY_IMAGES); OSG_ENUM_OPTIONS(DEEP_COPY_ARRAYS); OSG_ENUM_OPTIONS(DEEP_COPY_PRIMITIVES); OSG_ENUM_OPTIONS(DEEP_COPY_SHAPES); OSG_ENUM_OPTIONS(DEEP_COPY_ALL); } }