📄 databasepager.cpp
字号:
// ***************************************************************************//// Generated automatically by genwrapper.// Please DO NOT EDIT this file!//// ***************************************************************************#include <osgIntrospection/ReflectionMacros>#include <osgIntrospection/TypedMethodInfo>#include <osgIntrospection/StaticMethodInfo>#include <osgIntrospection/Attributes>#include <OpenThreads/Thread>#include <osg/FrameStamp>#include <osg/GraphicsContext>#include <osg/Group>#include <osg/Node>#include <osg/PagedLOD>#include <osg/Referenced>#include <osg/State>#include <osgDB/DatabasePager>#include <osgDB/ReaderWriter>// Must undefine IN and OUT macros defined in Windows headers#ifdef IN#undef IN#endif#ifdef OUT#undef OUT#endifTYPE_NAME_ALIAS(OpenThreads::Thread::ThreadPriority, osgDB::DatabasePager::ThreadPriority)TYPE_NAME_ALIAS(std::list< osg::ref_ptr< osg::PagedLOD > >, osgDB::DatabasePager::PagedLODList)TYPE_NAME_ALIAS(std::set< osg::ref_ptr< osg::StateSet > >, osgDB::DatabasePager::StateSetList)TYPE_NAME_ALIAS(std::vector< osg::ref_ptr< osg::Drawable > >, osgDB::DatabasePager::DrawableList)TYPE_NAME_ALIAS(std::pair< osgDB::DatabasePager::StateSetList COMMA osgDB::DatabasePager::DrawableList >, osgDB::DatabasePager::DataToCompile)TYPE_NAME_ALIAS(std::map< unsigned int COMMA osgDB::DatabasePager::DataToCompile >, osgDB::DatabasePager::DataToCompileMap)TYPE_NAME_ALIAS(std::set< unsigned int >, osgDB::DatabasePager::ActiveGraphicsContexts)TYPE_NAME_ALIAS(std::vector< osg::observer_ptr< osg::GraphicsContext > >, osgDB::DatabasePager::CompileGraphicsContexts)BEGIN_ENUM_REFLECTOR(osgDB::DatabasePager::DrawablePolicy) I_DeclaringFile("osgDB/DatabasePager"); I_EnumLabel(osgDB::DatabasePager::DO_NOT_MODIFY_DRAWABLE_SETTINGS); I_EnumLabel(osgDB::DatabasePager::USE_DISPLAY_LISTS); I_EnumLabel(osgDB::DatabasePager::USE_VERTEX_BUFFER_OBJECTS); I_EnumLabel(osgDB::DatabasePager::USE_VERTEX_ARRAYS);END_REFLECTORBEGIN_OBJECT_REFLECTOR(osgDB::DatabasePager) I_DeclaringFile("osgDB/DatabasePager"); I_BaseType(osg::NodeVisitor::DatabaseRequestHandler); I_Constructor0(____DatabasePager, "", ""); I_Constructor1(IN, const osgDB::DatabasePager &, rhs, Properties::NON_EXPLICIT, ____DatabasePager__C5_DatabasePager_R1, "", ""); I_Method0(osgDB::DatabasePager *, clone, Properties::VIRTUAL, __DatabasePager_P1__clone, "Create a shallow copy on the DatabasePager. ", ""); I_Method5(void, requestNodeFile, IN, const std::string &, fileName, IN, osg::Group *, group, IN, float, priority, IN, const osg::FrameStamp *, framestamp, IN, osg::ref_ptr< osg::Referenced > &, databaseRequest, Properties::VIRTUAL, __void__requestNodeFile__C5_std_string_R1__osg_Group_P1__float__C5_osg_FrameStamp_P1__osg_ref_ptrT1_osg_Referenced__R1, "Add a request to load a node file to end the the database request list. ", ""); I_Method6(void, requestNodeFile, IN, const std::string &, fileName, IN, osg::Group *, group, IN, float, priority, IN, const osg::FrameStamp *, framestamp, IN, osg::ref_ptr< osg::Referenced > &, databaseRequest, IN, osgDB::ReaderWriter::Options *, loadOptions, Properties::VIRTUAL, __void__requestNodeFile__C5_std_string_R1__osg_Group_P1__float__C5_osg_FrameStamp_P1__osg_ref_ptrT1_osg_Referenced__R1__ReaderWriter_Options_P1, "", ""); I_Method1(int, setSchedulePriority, IN, OpenThreads::Thread::ThreadPriority, priority, Properties::NON_VIRTUAL, __int__setSchedulePriority__OpenThreads_Thread_ThreadPriority, "Set the priority of the database pager thread(s). ", ""); I_Method0(int, cancel, Properties::VIRTUAL, __int__cancel, "Cancel the database pager thread(s). ", ""); I_Method0(bool, isRunning, Properties::VIRTUAL, __bool__isRunning, "", ""); I_Method0(void, clear, Properties::VIRTUAL, __void__clear, "Clear all internally cached structures. ", ""); I_MethodWithDefaults2(void, setUpThreads, IN, unsigned int, totalNumThreads, 2, IN, unsigned int, numHttpThreads, 1, Properties::NON_VIRTUAL, __void__setUpThreads__unsigned_int__unsigned_int, "", ""); I_Method2(unsigned int, addDatabaseThread, IN, osgDB::DatabasePager::DatabaseThread::Mode, mode, IN, const std::string &, name, Properties::NON_VIRTUAL, __unsigned_int__addDatabaseThread__DatabaseThread_Mode__C5_std_string_R1, "", ""); I_Method1(osgDB::DatabasePager::DatabaseThread *, getDatabaseThread, IN, unsigned int, i, Properties::NON_VIRTUAL, __DatabaseThread_P1__getDatabaseThread__unsigned_int, "", ""); I_Method1(const osgDB::DatabasePager::DatabaseThread *, getDatabaseThread, IN, unsigned int, i, Properties::NON_VIRTUAL, __C5_DatabaseThread_P1__getDatabaseThread__unsigned_int, "", ""); I_Method0(unsigned int, getNumDatabaseThreads, Properties::NON_VIRTUAL, __unsigned_int__getNumDatabaseThreads, "", ""); I_Method1(void, setDatabasePagerThreadPause, IN, bool, pause, Properties::NON_VIRTUAL, __void__setDatabasePagerThreadPause__bool, "Set whether the database pager thread should be paused or not. ", ""); I_Method0(bool, getDatabasePagerThreadPause, Properties::NON_VIRTUAL, __bool__getDatabasePagerThreadPause, "Get whether the database pager thread should is paused or not. ", ""); I_Method1(void, setAcceptNewDatabaseRequests, IN, bool, acceptNewRequests, Properties::NON_VIRTUAL, __void__setAcceptNewDatabaseRequests__bool, "Set whether new database request calls are accepted or ignored. ", ""); I_Method0(bool, getAcceptNewDatabaseRequests, Properties::NON_VIRTUAL, __bool__getAcceptNewDatabaseRequests, "Get whether new database request calls are accepted or ignored. ", ""); I_Method0(int, getNumFramesActive, Properties::NON_VIRTUAL, __int__getNumFramesActive, "Get the number of frames that are currently active. ", ""); I_Method1(void, signalBeginFrame, IN, const osg::FrameStamp *, framestamp, Properties::VIRTUAL, __void__signalBeginFrame__C5_osg_FrameStamp_P1, "Signal the database thread that the update, cull and draw has begun for a new frame. ", "Note, this is called by the application so that the database pager can go to sleep while the CPU is busy on the main rendering threads. "); I_Method0(void, signalEndFrame, Properties::VIRTUAL, __void__signalEndFrame, "Signal the database thread that the update, cull and draw dispatch has completed. ", "Note, this is called by the application so that the database pager can go to wake back up now the main rendering threads are iddle waiting for the next frame. "); I_MethodWithDefaults2(void, registerPagedLODs, IN, osg::Node *, subgraph, , IN, int, frameNumber, 0, Properties::VIRTUAL, __void__registerPagedLODs__osg_Node_P1__int, "Find all PagedLOD nodes in a subgraph and register them with the DatabasePager so it can keep track of expired nodes. ", "note, should be only be called from the update thread. "); I_Method1(void, setDoPreCompile, IN, bool, flag, Properties::NON_VIRTUAL, __void__setDoPreCompile__bool, "Set whether the database pager should pre compile OpenGL objects before allowing them to be merged into the scene graph. ", "Pre compilation helps reduce the chances of frame drops, but also slows the speed at which tiles are merged as they have to be compiled first. "); I_Method0(bool, getDoPreCompile, Properties::NON_VIRTUAL, __bool__getDoPreCompile, "Get whether the database pager should pre compile OpenGL objects before allowing them to be merged into the scene graph. ", ""); I_Method1(void, setTargetFrameRate, IN, double, tfr, Properties::NON_VIRTUAL, __void__setTargetFrameRate__double, "Set the target frame rate that the DatabasePager should assume. ", "Typically one would set this to the value refresh rate of your display system i.e. 60Hz. Default value is 100. Usage notes. The TargetFrameRate and the MinimumTimeAvailableForGLCompileAndDeletePerFrame parameters are not directly used by DatabasePager, but are should be used as a guide for how long to set aside per frame for compiling and deleting OpenGL objects - ie. the value to use when calling DatabasePager::compileGLObjectgs(state,availableTime,). The longer amount of time to set aside cthe faster databases will be paged in but with increased chance of frame drops, the lower the amount of time the set aside the slower databases will paged it but with better chance of avoid any frame drops. The default values are chosen to achieve the later when running on a modern mid to high end PC. The way to compute the amount of available time use a scheme such as : availableTime = maximum(1.0/targetFrameRate - timeTakenDuringUpdateCullAndDraw, minimumTimeAvailableForGLCompileAndDeletePerFrame). "); I_Method0(double, getTargetFrameRate, Properties::NON_VIRTUAL, __double__getTargetFrameRate, "Get the target frame rate that the DatabasePager should assume. ", ""); I_Method1(void, setMinimumTimeAvailableForGLCompileAndDeletePerFrame, IN, double, ta, Properties::NON_VIRTUAL, __void__setMinimumTimeAvailableForGLCompileAndDeletePerFrame__double, "Set the minimum amount of time (in seconds) that should be made available for compiling and delete OpenGL objects per frame. ", "Default value is 0.001 (1 millisecond). For usage see notes in setTargetFrameRate. "); I_Method0(double, getMinimumTimeAvailableForGLCompileAndDeletePerFrame, Properties::NON_VIRTUAL, __double__getMinimumTimeAvailableForGLCompileAndDeletePerFrame, "Get the minimum amount of time that should be made available for compiling and delete OpenGL objects per frame. ", "For usage see notes in setTargetFrameRate. "); I_Method1(void, setMaximumNumOfObjectsToCompilePerFrame, IN, unsigned int, num, Properties::NON_VIRTUAL, __void__setMaximumNumOfObjectsToCompilePerFrame__unsigned_int, "Set the maximum number of OpenGL objects that the page should attempt to compile per frame. ", "Note, Lower values reduces chances of a frame drop but lower the rate that database will be paged in at. Default value is 8. "); I_Method0(unsigned int, getMaximumNumOfObjectsToCompilePerFrame, Properties::NON_VIRTUAL, __unsigned_int__getMaximumNumOfObjectsToCompilePerFrame, "Get the maximum number of OpenGL objects that the page should attempt to compile per frame. ", ""); I_Method1(void, setExpiryDelay, IN, double, expiryDelay, Properties::NON_VIRTUAL, __void__setExpiryDelay__double, "Set the amount of time that a subgraph will be kept without being visited in the cull traversal before being removed. ", ""); I_Method0(double, getExpiryDelay, Properties::NON_VIRTUAL, __double__getExpiryDelay, "Get the amount of time that a subgraph will be kept without being visited in the cull traversal before being removed. ", "");
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -