loaderFileType.cxx 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. // Filename: loaderFileType.cxx
  2. // Created by: drose (20Jun00)
  3. //
  4. ////////////////////////////////////////////////////////////////////
  5. //
  6. // PANDA 3D SOFTWARE
  7. // Copyright (c) 2001, Disney Enterprises, Inc. All rights reserved
  8. //
  9. // All use of this software is subject to the terms of the Panda 3d
  10. // Software license. You should have received a copy of this license
  11. // along with this source code; you will also find a current copy of
  12. // the license at http://www.panda3d.org/license.txt .
  13. //
  14. // To contact the maintainers of this program write to
  15. // [email protected] .
  16. //
  17. ////////////////////////////////////////////////////////////////////
  18. #include "loaderFileType.h"
  19. TypeHandle LoaderFileType::_type_handle;
  20. ////////////////////////////////////////////////////////////////////
  21. // Function: LoaderFileType::Constructor
  22. // Access: Protected
  23. // Description:
  24. ////////////////////////////////////////////////////////////////////
  25. LoaderFileType::
  26. LoaderFileType() {
  27. }
  28. ////////////////////////////////////////////////////////////////////
  29. // Function: LoaderFileType::Destructor
  30. // Access: Public, Virtual
  31. // Description:
  32. ////////////////////////////////////////////////////////////////////
  33. LoaderFileType::
  34. ~LoaderFileType() {
  35. }
  36. ////////////////////////////////////////////////////////////////////
  37. // Function: LoaderFileType::resolve_filename
  38. // Access: Public, Virtual
  39. // Description: Searches for the indicated filename on whatever paths
  40. // are appropriate to this file type, and updates it if
  41. // it is found. It is not necessary to call this before
  42. // calling load_file(), but it doesn't hurt; this is
  43. // useful for when the loader needs to know the full
  44. // pathname to the exact file it will be loading.
  45. ////////////////////////////////////////////////////////////////////
  46. void LoaderFileType::
  47. resolve_filename(Filename &) const {
  48. }
  49. ////////////////////////////////////////////////////////////////////
  50. // Function: LoaderFileType::load_file
  51. // Access: Public, Virtual
  52. // Description:
  53. ////////////////////////////////////////////////////////////////////
  54. PT(PandaNode) LoaderFileType::
  55. load_file(const Filename &path, bool report_errors) const {
  56. loader_cat.error()
  57. << get_type() << " cannot read PandaNode objects.\n";
  58. return NULL;
  59. }