Something went wrong on our end
-
Ansgar Philippsen authored
The scene background can now be a gradient or a bitmap image in addition to a static color; use scene.SetBackground(gfx.Gradient) or scene.SetBackground(gfx.Bitmap) for this purpose. The gfx.Bitmap class and its import/export functions have been exported to Python. Some cleanup in the OpenGL code to (i) avoid premature rendering before full initialization and (ii) streamline error checking a bit.
Ansgar Philippsen authoredThe scene background can now be a gradient or a bitmap image in addition to a static color; use scene.SetBackground(gfx.Gradient) or scene.SetBackground(gfx.Bitmap) for this purpose. The gfx.Bitmap class and its import/export functions have been exported to Python. Some cleanup in the OpenGL code to (i) avoid premature rendering before full initialization and (ii) streamline error checking a bit.
CMakeLists.txt 840 B
set(OST_GFX_PYMOD_SOURCES
wrap_gfx.cc
export_scene.cc
export_gfx_node.cc
export_symmetry_node.cc
export_gfx_obj.cc
export_entity.cc
export_surface.cc
export_primitives.cc
export_primlist.cc
export_scene_observer.cc
export_render_options.cc
export_color.cc
export_gradient.cc
export_color_ops.cc
export_glwin_base.cc
export_exporter.cc
export_bitmap.cc
)
if (ENABLE_IMG)
set(OST_GFX_PYMOD_SOURCES ${OST_GFX_PYMOD_SOURCES} export_map.cc)
endif()
pymod(NAME gfx CPP ${OST_GFX_PYMOD_SOURCES} PY __init__.py py_gfx_obj.py)
set(GRADIENT_FILE
gradients.xml
)
copy_if_different("${CMAKE_CURRENT_SOURCE_DIR}" "${STAGE_DIR}/share/openstructure/scene"
"${GRADIENT_FILE}" "PRESET GRADIENTS" _ost_gfx)
install(FILES ${GRADIENT_FILE} DESTINATION "share/openstructure/scene")