tinyTextureContext.I 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. // Filename: tinyTextureContext.I
  2. // Created by: drose (30Apr08)
  3. //
  4. ////////////////////////////////////////////////////////////////////
  5. //
  6. // PANDA 3D SOFTWARE
  7. // Copyright (c) Carnegie Mellon University. All rights reserved.
  8. //
  9. // All use of this software is subject to the terms of the revised BSD
  10. // license. You should have received a copy of this license along
  11. // with this source code in a file named "LICENSE."
  12. //
  13. ////////////////////////////////////////////////////////////////////
  14. ////////////////////////////////////////////////////////////////////
  15. // Function: TinyTextureContext::Constructor
  16. // Access: Public
  17. // Description:
  18. ////////////////////////////////////////////////////////////////////
  19. INLINE TinyTextureContext::
  20. TinyTextureContext(PreparedGraphicsObjects *pgo, Texture *tex, int view) :
  21. TextureContext(pgo, tex, view)
  22. {
  23. _gltex.num_levels = 0;
  24. _gltex.allocated_buffer = NULL;
  25. _gltex.total_bytecount = 0;
  26. }
  27. ////////////////////////////////////////////////////////////////////
  28. // Function: TinyTextureContext::Destructor
  29. // Access: Public
  30. // Description:
  31. ////////////////////////////////////////////////////////////////////
  32. INLINE TinyTextureContext::
  33. ~TinyTextureContext() {
  34. nassertv(_gltex.num_levels == 0 && _gltex.allocated_buffer == NULL && _gltex.total_bytecount == 0);
  35. }