Changeset 6647 in orxonox.OLD for trunk/src/util
- Timestamp:
- Jan 21, 2006, 6:01:43 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/util/loading/resource_manager.cc
r6646 r6647 50 50 51 51 /** 52 * standard constructor52 * @brief standard constructor 53 53 */ 54 54 ResourceManager::ResourceManager () … … 66 66 67 67 /** 68 * standard destructor68 * @brief standard destructor 69 69 */ 70 70 ResourceManager::~ResourceManager () … … 89 89 90 90 /** 91 * sets the data main directory91 * @brief sets the data main directory 92 92 * @param dataDir the DataDirectory. 93 93 */ … … 122 122 123 123 /** 124 * sets the data main directory124 * @brief sets the data main directory 125 125 * @param dataDir the DataDirectory. 126 126 * … … 153 153 154 154 155 156 /** 157 * checks for the DataDirectory, by looking if 155 /** 156 * @brief checks for the DataDirectory, by looking if 158 157 * @param fileInside is iniside of the given directory. 159 158 */ … … 176 175 #ifndef NO_TEXTURES 177 176 /** 178 * adds a new Path for Images177 * @brief adds a new Path for Images 179 178 * @param imageDir The path to insert 180 179 * @returns true, if the Path was well and injected (or already existent within the list) … … 227 226 228 227 /** 229 * loads resources228 * @brief loads resources 230 229 * @param fileName: The fileName of the resource to load 231 230 * @param prio: The ResourcePriority of this resource (will only be increased) … … 295 294 296 295 /** 297 * caches a Resource296 * @brief caches a Resource 298 297 * 299 298 * @see load; … … 323 322 324 323 /** 325 * loads resources324 * @brief loads resources 326 325 * @param fileName: The fileName of the resource to load 327 326 * @param type: The Type of Resource to load. … … 358 357 359 358 /** 360 * loads resources for internal purposes359 * @brief loads resources for internal purposes 361 360 * @param fileName: The fileName of the resource to load 362 361 * @param type: The Type of Resource to load. … … 529 528 530 529 /** 531 * unloads a Resource530 * @brief unloads a Resource 532 531 * @param pointer: The pointer to free 533 532 * @param prio: the PriorityLevel to unload this resource … … 550 549 551 550 /** 552 * unloads a Resource551 * @brief unloads a Resource 553 552 * @param resource: The resource to unloade 554 553 * @param prio the PriorityLevel to unload this resource … … 623 622 624 623 /** 625 * unloads all alocated Memory of Resources with a pririty lower than prio624 * @brief unloads all alocated Memory of Resources with a pririty lower than prio 626 625 * @param prio The priority to delete 627 626 */ … … 654 653 655 654 /** 656 * Searches for a Resource by some information655 * @brief Searches for a Resource by some information 657 656 * @param fileName: The name to look for 658 657 * @param type the Type of resource to locate. … … 671 670 { 672 671 bool match = false; 673 674 672 switch (type) 675 673 { … … 682 680 match = true; 683 681 } 684 else if ((*resource)->param[0] == param0 )682 else if ((*resource)->param[0] == param0.getFloat()) 685 683 match = true; 686 684 break; … … 691 689 match = true; 692 690 } 693 else if ((*resource)->param[0] == param0)691 else if ((*resource)->param[0] == ((MultiType)param0).getString()) 694 692 match = true; 695 693 break; … … 702 700 match = true; 703 701 } 704 else if ((*resource)->param[0] == param0 )702 else if ((*resource)->param[0] == param0.getInt()) 705 703 match = true; 706 704 break; … … 713 711 match = true; 714 712 } 715 else if ((*resource)->param[0] == param0)713 else if ((*resource)->param[0] == ((MultiType)param0).getString()) 716 714 match = true; 717 715 #endif /* NO_SHADERS */ … … 723 721 match = true; 724 722 } 725 else if ((*resource)->param[0] == param0 )723 else if ((*resource)->param[0] == param0.getInt()) 726 724 match = true; 727 725 #endif /* NO_TEXTURES */ … … 740 738 741 739 /** 742 * Searches for a Resource by Pointer740 * @brief Searches for a Resource by Pointer 743 741 * @param pointer the Pointer to search for 744 742 * @returns a Pointer to the Resource if found, NULL otherwise. 745 */743 */ 746 744 Resource* ResourceManager::locateResourceByPointer(const void* pointer) const 747 745 { … … 755 753 756 754 /** 757 * Checks if it is a Directory755 * @brief Checks if it is a Directory 758 756 * @param directoryName the Directory to check for 759 757 * @returns true if it is a directory/symlink false otherwise … … 806 804 807 805 /** 808 * Checks if the file is either a Regular file or a Symlink806 * @brief Checks if the file is either a Regular file or a Symlink 809 807 * @param fileName the File to check for 810 808 * @returns true if it is a regular file/symlink, false otherwise … … 842 840 843 841 /** 844 * touches a File on the disk (thereby creating it)842 * @brief touches a File on the disk (thereby creating it) 845 843 * @param fileName The file to touch 846 844 */ … … 863 861 864 862 /** 865 * deletes a File from disk863 * @brief deletes a File from disk 866 864 * @param fileName the File to delete 867 865 */ … … 928 926 929 927 /** 930 * checks wether a file is in the DataDir.928 * @brief checks wether a file is in the DataDir. 931 929 * @param fileName the File to check if it is in the Data-Dir structure. 932 930 * @returns true if the file exists, false otherwise … … 952 950 953 951 /** 954 * outputs debug information about the ResourceManager955 */952 * @brief outputs debug information about the ResourceManager 953 */ 956 954 void ResourceManager::debug() const 957 955 { … … 1002 1000 1003 1001 /** 1004 * converts a ResourceType into the corresponding String1002 * @brief converts a ResourceType into the corresponding String 1005 1003 * @param type the ResourceType to translate 1006 1004 * @returns the converted String.
Note: See TracChangeset
for help on using the changeset viewer.