David Rose 23 лет назад
Родитель
Сommit
a33194e89f

+ 1 - 1
panda/src/chancfg/chancfg.cxx

@@ -29,7 +29,7 @@
 #include "filename.h"
 #include "transformState.h"
 #include "dcast.h"
-#include "config_util.h"
+#include "config_express.h"
 #include "virtualFileSystem.h"
 
 #include <algorithm>

+ 1 - 0
panda/src/egg/eggData.cxx

@@ -25,6 +25,7 @@
 #include "config_egg.h"
 
 #include "config_util.h"
+#include "config_express.h"
 #include "string_utils.h"
 #include "dSearchPath.h"
 #include "virtualFileSystem.h"

+ 1 - 0
panda/src/egg2pg/load_egg_file.cxx

@@ -22,6 +22,7 @@
 #include "sceneGraphReducer.h"
 #include "virtualFileSystem.h"
 #include "config_util.h"
+#include "config_express.h"
 
 static PT(PandaNode)
 load_from_loader(EggLoader &loader) {

+ 7 - 1
panda/src/express/config_express.cxx

@@ -41,8 +41,8 @@ ConfigureFn(config_express) {
   ReferenceCount::init_type();
   TypedObject::init_type();
   TypedReferenceCount::init_type();
-  VirtualFileComposite::init_type();
   VirtualFile::init_type();
+  VirtualFileComposite::init_type();
   VirtualFileMount::init_type();
   VirtualFileMountMultifile::init_type();
   VirtualFileMountSystem::init_type();
@@ -146,6 +146,12 @@ const int patchfile_buffer_size =
 const int patchfile_zone_size =
         config_express.GetInt("patchfile-zone-size", 10000);
 
+// Set this true to use the VirtualFileSystem mechanism for loading
+// models, etc.  Since the VirtualFileSystem maps to the same as the
+// actual file system by default, there is probably no reason to set
+// this false, except for testing or if you mistrust the new code.
+const bool use_vfs = config_express.GetBool("use-vfs", true);
+
 
 // Returns the configure object for accessing config variables from a
 // scripting language.

+ 5 - 3
panda/src/express/config_express.h

@@ -19,9 +19,9 @@
 #ifndef __CONFIG_EXPRESS_H__
 #define __CONFIG_EXPRESS_H__
 
-#include <pandabase.h>
-#include <notifyCategoryProxy.h>
-#include <dconfig.h>
+#include "pandabase.h"
+#include "notifyCategoryProxy.h"
+#include "dconfig.h"
 
 ConfigureDecl(config_express, EXPCL_PANDAEXPRESS, EXPTP_PANDAEXPRESS);
 NotifyCategoryDecl(express, EXPCL_PANDAEXPRESS, EXPTP_PANDAEXPRESS);
@@ -45,6 +45,8 @@ extern const int patchfile_increment_size;
 extern const int patchfile_buffer_size;
 extern const int patchfile_zone_size;
 
+extern EXPCL_PANDAEXPRESS const bool use_vfs;
+
 // Expose the Config variable for Python access.
 BEGIN_PUBLISH
 typedef Config::Config<ConfigureGetConfig_config_express> ConfigExpress;

+ 1 - 0
panda/src/gobj/texturePool.cxx

@@ -19,6 +19,7 @@
 #include "texturePool.h"
 #include "config_gobj.h"
 #include "config_util.h"
+#include "config_express.h"
 #include "virtualFileSystem.h"
 
 

+ 1 - 0
panda/src/pgraph/bamFile.cxx

@@ -24,6 +24,7 @@
 #include "bamReader.h"
 #include "bamWriter.h"
 #include "filename.h"
+#include "config_express.h"
 #include "virtualFileSystem.h"
 
 ////////////////////////////////////////////////////////////////////

+ 1 - 1
panda/src/pgraph/loader.cxx

@@ -21,7 +21,7 @@
 #include "loaderFileTypeRegistry.h"
 #include "config_pgraph.h"
 
-#include "config_util.h"
+#include "config_express.h"
 #include "virtualFileSystem.h"
 #include "event.h"
 #include "pt_Event.h"

+ 2 - 1
panda/src/pgraph/loaderFileTypeBam.cxx

@@ -20,8 +20,9 @@
 #include "config_pgraph.h"
 #include "bamFile.h"
 
-#include "virtualFileSystem.h"
 #include "config_util.h"
+#include "config_express.h"
+#include "virtualFileSystem.h"
 #include "dcast.h"
 
 TypeHandle LoaderFileTypeBam::_type_handle;

+ 1 - 1
panda/src/pnmimage/pnmImageHeader.cxx

@@ -21,8 +21,8 @@
 #include "pnmFileType.h"
 #include "pnmReader.h"
 #include "config_pnmimage.h"
+#include "config_express.h"
 #include "virtualFileSystem.h"
-#include "config_util.h"
 
 ////////////////////////////////////////////////////////////////////
 //     Function: PNMImageHeader::read_header

+ 0 - 6
panda/src/putil/config_util.cxx

@@ -88,9 +88,3 @@ get_sound_path() {
   static DSearchPath *sound_path = NULL;
   return get_config_path("sound-path", sound_path);
 }
-
-// Set this true to use the VirtualFileSystem mechanism for loading
-// models, etc.  Since the VirtualFileSystem maps to the same as the
-// actual file system by default, there is probably no reason to set
-// this false, except for testing or if you mistrust the new code.
-const bool use_vfs = config_util.GetBool("use-vfs", true);

+ 3 - 5
panda/src/putil/config_util.h

@@ -19,9 +19,9 @@
 #ifndef __CONFIG_UTIL_H__
 #define __CONFIG_UTIL_H__
 
-#include <pandabase.h>
-#include <notifyCategoryProxy.h>
-#include <dconfig.h>
+#include "pandabase.h"
+#include "notifyCategoryProxy.h"
+#include "dconfig.h"
 
 class DSearchPath;
 
@@ -46,6 +46,4 @@ EXPCL_PANDA DSearchPath &get_texture_path();
 EXPCL_PANDA DSearchPath &get_sound_path();
 END_PUBLISH
 
-extern EXPCL_PANDA const bool use_vfs;
-
 #endif /* __CONFIG_UTIL_H__ */

+ 1 - 0
panda/src/putil/datagramInputFile.cxx

@@ -21,6 +21,7 @@
 #include "datagramIterator.h"
 #include "profileTimer.h"
 #include "config_util.h"
+#include "config_express.h"
 #include "virtualFileSystem.h"
 
 #include "datagramInputFile.h"