Changeset 4961 in orxonox.OLD for orxonox/trunk/src/util
- Timestamp:
- Jul 28, 2005, 1:19:50 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/util/resource_manager.cc
r4836 r4961 34 34 #ifndef NO_AUDIO 35 35 #include "sound_engine.h" 36 #include "ogg_player.h" 36 37 #endif /* NO_AUDIO */ 37 38 … … 228 229 229 230 /** 230 * 231 * loads resources 231 232 * @param fileName: The fileName of the resource to load 232 233 * @param type: The Type of Resource to load (\see ResourceType) … … 346 347 if(isFile(fullName)) 347 348 tmpResource->pointer = new SoundBuffer(fullName); 349 break; 350 case OGG: 351 if (isFile(fullName)) 352 tmpResource->pointer = new OggPlayer(fullName); 348 353 break; 349 354 #endif /* NO_AUDIO */ … … 400 405 401 406 /** 402 * 407 * unloads a Resource 403 408 * @param pointer: The pointer to free 404 409 * @param prio: the PriorityLevel to unload this resource … … 419 424 420 425 /** 421 * 426 * unloads a Resource 422 427 * @param resource: The resource to unloade 423 428 * @param prio the PriorityLevel to unload this resource … … 446 451 case WAV: 447 452 delete (SoundBuffer*)resource->pointer; 453 break; 454 case OGG: 455 delete (OggPlayer*)resource->pointer; 448 456 break; 449 457 #endif /* NO_AUDIO */ … … 500 508 501 509 /** 502 * 510 * Searches for a Resource by some information 503 511 * @param fileName: The name to look for 504 512 * @param type the Type of resource to locate. … … 587 595 588 596 /** 589 * 597 * Searches for a Resource by Pointer 590 598 * @param pointer the Pointer to search for 591 599 * @returns a Pointer to the Resource if found, NULL otherwise. … … 610 618 611 619 /** 612 * 620 * Checks if it is a Directory 613 621 * @param directoryName the Directory to check for 614 622 * @returns true if it is a directory/symlink false otherwise … … 657 665 658 666 /** 659 * 667 * Checks if the file is either a Regular file or a Symlink 660 668 * @param fileName the File to check for 661 669 * @returns true if it is a regular file/symlink, false otherwise … … 693 701 694 702 /** 695 * 703 * touches a File on the disk (thereby creating it) 696 704 * @param fileName The file to touch 697 705 */ … … 713 721 714 722 /** 715 * 723 * deletes a File from disk 716 724 * @param fileName the File to delete 717 725 */ … … 726 734 727 735 /** 728 729 730 731 */736 * @param name the Name of the file to check 737 * @returns The name of the file, including the HomeDir 738 * IMPORTANT: this has to be deleted from the outside 739 */ 732 740 char* ResourceManager::homeDirCheck(const char* name) 733 741 { … … 755 763 756 764 /** 757 758 759 765 * @param fileName the Name of the File to check 766 * @returns The full name of the file, including the DataDir, and NULL if the file does not exist 767 * IMPORTANT: this has to be deleted from the outside 760 768 */ 761 769 char* ResourceManager::getFullName(const char* fileName) … … 778 786 779 787 /** 780 * 788 * outputs debug information about the ResourceManager 781 789 */ 782 790 void ResourceManager::debug() const … … 824 832 case WAV: 825 833 PRINT(0)("SoundFile\n"); 834 break; 835 case OGG: 836 PRINT(0)("MusicFile\n"); 837 break; 826 838 #endif 827 839 default:
Note: See TracChangeset
for help on using the changeset viewer.