1#ifndef COIN_SOGUIMATERIALEDITOR_H 2#define COIN_SOGUIMATERIALEDITOR_H 3 4// @configure_input@ 5 6/**************************************************************************\ 7 * 8 * This file is part of the Coin 3D visualization library. 9 * Copyright (C) by Kongsberg Oil & Gas Technologies. 10 * 11 * This library is free software; you can redistribute it and/or 12 * modify it under the terms of the GNU General Public License 13 * ("GPL") version 2 as published by the Free Software Foundation. 14 * See the file LICENSE.GPL at the root directory of this source 15 * distribution for additional information about the GNU GPL. 16 * 17 * For using Coin with software that can not be combined with the GNU 18 * GPL, and for taking advantage of the additional benefits of our 19 * support services, please contact Kongsberg Oil & Gas Technologies 20 * about acquiring a Coin Professional Edition License. 21 * 22 * See http://www.coin3d.org/ for more information. 23 * 24 * Kongsberg Oil & Gas Technologies, Bygdoy Alle 5, 0257 Oslo, NORWAY. 25 * http://www.sim.no/ sales@sim.no coin-support@coin3d.org 26 * 27\**************************************************************************/ 28 29#include <Inventor/fields/SoSFEnum.h> 30#include <Inventor/fields/SoSFShort.h> 31#include <Inventor/fields/SoSFNode.h> 32#include <Inventor/nodekits/SoBaseKit.h> 33 34class SoMaterial; 35class SoGuiColorEditor; 36 37typedef SoGuiColorEditor * SoGuiColorEditorOpenCB(void * closure); 38typedef void SoGuiColorEditorCloseCB(void * closure, SoGuiColorEditor * editor); 39 40class SoGuiMaterialEditor : public SoBaseKit { 41 typedef SoBaseKit inherited; 42 SO_KIT_HEADER(SoGuiMaterialEditor); 43 SO_KIT_CATALOG_ENTRY_HEADER(root); 44 45public: 46 static void initClass(void); 47 SoGuiMaterialEditor(void); 48 49 enum UpdateFrequency { 50 CONTINUOUS, 51 AFTER_ACCEPT 52 }; 53 54 SoSFNode material; 55 SoSFShort index; 56 SoSFEnum update; 57 58 void setColorEditorCallbacks(SoGuiColorEditorOpenCB * open, SoGuiColorEditorCloseCB * close, void * closure); 59 SoMaterial * getSphereMaterialNode(void) const; 60 61protected: 62 ~SoGuiMaterialEditor(void); 63 64private: 65 void * internals; 66 67}; 68 69#endif // !COIN_SOGUIMATERIALEDITOR_H 70