示例#1
0
文件: PhysFS.cs 项目: magiccpp/physfs
        public unsafe static string[] GetCDROMDrives()
        {
            byte **p;           // CDROM list from PhysFS dll

            string[] cdromlist; // List converted to an array

            // Get the CDROM drive listing
            p = PhysFS_DLL.PHYSFS_getCdRomDirs();
            // Convert the C-style array to a .NET style array
            cdromlist = PhysFS_DLL.BytePPToArray(p);
            // Free the original list since we're done with it
            PhysFS_DLL.PHYSFS_freeList(p);

            return(cdromlist);
        }
示例#2
0
文件: PhysFS.cs 项目: magiccpp/physfs
        public unsafe static string[] EnumerateFiles(string Dirname)
        {
            byte **p;           // File list from PhysFS dll

            string[] filelist;  // List converted to an array

            // Get the CDROM drive listing
            p = PhysFS_DLL.PHYSFS_enumerateFiles(Dirname);
            // Convert the C-style array to a .NET style array
            filelist = PhysFS_DLL.BytePPToArray(p);
            // Free the original list since we're done with it
            PhysFS_DLL.PHYSFS_freeList(p);

            return(filelist);
        }
示例#3
0
文件: PhysFS.cs 项目: magiccpp/physfs
        public unsafe static string[] GetSearchPath()
        {
            byte **p;           // Searchpath list from PhysFS dll

            string[] pathlist;  // List converted to an array

            // Get the CDROM drive listing
            p = PhysFS_DLL.PHYSFS_getSearchPath();
            // Convert the C-style array to a .NET style array
            pathlist = PhysFS_DLL.BytePPToArray(p);
            // Free the original list since we're done with it
            PhysFS_DLL.PHYSFS_freeList(p);

            return(pathlist);
        }