Panda3D
|
00001 // Filename: cullBinBackToFront.I 00002 // Created by: drose (28Feb02) 00003 // 00004 //////////////////////////////////////////////////////////////////// 00005 // 00006 // PANDA 3D SOFTWARE 00007 // Copyright (c) Carnegie Mellon University. All rights reserved. 00008 // 00009 // All use of this software is subject to the terms of the revised BSD 00010 // license. You should have received a copy of this license along 00011 // with this source code in a file named "LICENSE." 00012 // 00013 //////////////////////////////////////////////////////////////////// 00014 00015 00016 //////////////////////////////////////////////////////////////////// 00017 // Function: CullBinBackToFront::Constructor 00018 // Access: Public 00019 // Description: 00020 //////////////////////////////////////////////////////////////////// 00021 INLINE CullBinBackToFront:: 00022 CullBinBackToFront(const string &name, GraphicsStateGuardianBase *gsg, 00023 const PStatCollector &draw_region_pcollector) : 00024 CullBin(name, BT_back_to_front, gsg, draw_region_pcollector) 00025 { 00026 } 00027 00028 //////////////////////////////////////////////////////////////////// 00029 // Function: CullBinBackToFront::ObjectData::Constructor 00030 // Access: Public 00031 // Description: 00032 //////////////////////////////////////////////////////////////////// 00033 INLINE CullBinBackToFront::ObjectData:: 00034 ObjectData(CullableObject *object, PN_stdfloat dist) : 00035 _object(object), 00036 _dist(dist) 00037 { 00038 } 00039 00040 //////////////////////////////////////////////////////////////////// 00041 // Function: CullBinBackToFront::ObjectData::operator < 00042 // Access: Public 00043 // Description: Specifies the correct sort ordering for these 00044 // objects. 00045 //////////////////////////////////////////////////////////////////// 00046 INLINE bool CullBinBackToFront::ObjectData:: 00047 operator < (const ObjectData &other) const { 00048 return _dist > other._dist; 00049 } 00050