瀏覽代碼

IOSystem: add missing documentation.

Kim Kulling 10 年之前
父節點
當前提交
e9937ab0f7
共有 2 個文件被更改,包括 24 次插入10 次删除
  1. 2 4
      code/ObjFileParser.cpp
  2. 22 6
      include/assimp/IOSystem.hpp

+ 2 - 4
code/ObjFileParser.cpp

@@ -544,12 +544,10 @@ void ObjFileParser::getMaterialLib()
     } else {
         absName = strMatName;
     }
-    //IOStream *pFile = m_pIO->Open( strMatName );
     IOStream *pFile = m_pIO->Open( absName );
 
-    if (!pFile )
-    {
-        DefaultLogger::get()->error("OBJ: Unable to locate material file " + strMatName );
+    if (!pFile ) {
+        DefaultLogger::get()->error( "OBJ: Unable to locate material file " + strMatName );
         m_DataIt = skipLine<DataArrayIt>( m_DataIt, m_DataItEnd, m_uiLine );
         return;
     }

+ 22 - 6
include/assimp/IOSystem.hpp

@@ -105,18 +105,14 @@ public:
      * @param pFile Path to the file
      * @return true if there is a file with this path, else false.
      */
-
     virtual bool Exists( const char* pFile) const = 0;
 
-
-
     // -------------------------------------------------------------------
     /** @brief Returns the system specific directory separator
      *  @return System specific directory separator
      */
     virtual char getOsSeparator() const = 0;
 
-
     // -------------------------------------------------------------------
     /** @brief Open a new file with a given path.
      *
@@ -142,8 +138,6 @@ public:
     inline IOStream* Open(const std::string& pFile,
         const std::string& pMode = std::string("rb"));
 
-
-
     // -------------------------------------------------------------------
     /** @brief Closes the given file and releases all resources
      *    associated with it.
@@ -174,9 +168,31 @@ public:
     inline bool ComparePaths (const std::string& one,
         const std::string& second) const;
 
+    // -------------------------------------------------------------------
+    /** @brief Pushes a new directory onto the directory stack.
+     *  @param path Path to push onto the stack.
+     *  @return True, when push was successful, false if path is empty.
+     */
     virtual bool PushDirectory( const std::string &path );
+
+    // -------------------------------------------------------------------
+    /** @brief Returns the top directory from the stack.
+     *  @return The directory on the top of the stack.
+     *          Returns empty when no directory was pushed to the stack.
+     */
     virtual const std::string &CurrentDirectory() const;
+
+    // -------------------------------------------------------------------
+    /** @brief Returns the number of directories stored on the stack.
+     *  @return The number of directories of the stack.
+     */
     virtual size_t StackSize() const;
+
+    // -------------------------------------------------------------------
+    /** @brief Pops the top directory from the stack.
+     *  @return True, when a directory was on the stack. False if no
+     *          directory was on the stack.
+     */
     virtual bool PopDirectory();
 
 private: