![]() |
Shadowrun: Awakened 29 September 2011 - Build 871
|
#include <vector>#include <iostream>#include "pover_video.h"#include "tbb/scalable_allocator.h"
Include dependency graph for rpolygon.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Classes | |
| class | RPolygon |
| class | RPolygon_flagged |
Typedefs | |
| typedef class vector < RPolygon_flagged > | Flagged_map_t |
| typedef class vector< RPolygon * > | Polygon_map_t |
| typedef scalable_allocator < RPolygon > | RPolygon_allocator |
Enumerations | |
| enum | MallocBehavior { UseMalloc, UseScalableAllocator } |
Functions | |
| DEFINE MallocBehavior gMBehavior | INIT (UseScalableAllocator) |
| ostream & | operator<< (ostream &s, const RPolygon &p) |
| bool | PolygonsOverlap (RPolygon *p1, RPolygon *p2, int &xl, int &yl, int &xh, int &yh) |
Variables | |
| DEFINE RPolygon_allocator | rAlloc |
| typedef class vector< RPolygon_flagged > Flagged_map_t |
Definition at line 155 of file rpolygon.h.
| typedef class vector< RPolygon * > Polygon_map_t |
Definition at line 154 of file rpolygon.h.
| typedef scalable_allocator<RPolygon> RPolygon_allocator |
Definition at line 43 of file rpolygon.h.
| enum MallocBehavior |
Definition at line 47 of file rpolygon.h.
| DEFINE MallocBehavior gMBehavior INIT | ( | UseScalableAllocator | ) |
| ostream& operator<< | ( | ostream & | s, |
| const RPolygon & | p | ||
| ) |
Definition at line 627 of file polymain.cpp.
References RPolygon::get().
| bool PolygonsOverlap | ( | RPolygon * | p1, |
| RPolygon * | p2, | ||
| int & | xl, | ||
| int & | yl, | ||
| int & | xh, | ||
| int & | yh | ||
| ) | [inline] |
Definition at line 157 of file rpolygon.h.
References RPolygon::get(), and rt_sleep().
Referenced by OverlayOnePolygonWithMap().
{
int xl1, yl1, xh1, yh1, xl2, yl2, xh2, yh2;
#if _DEBUG
rt_sleep(1); // slow down the process so we can see it.
#endif
p1->get(&xl1, &yl1, &xh1, &yh1);
p2->get(&xl2, &yl2, &xh2, &yh2);
if(xl1 > xh2) return false;
if(xh1 < xl2) return false;
if(yl1 > yh2) return false;
if(yh1 < yl2) return false;
xl = (xl1 < xl2) ? xl2 : xl1;
xh = (xh1 < xh2) ? xh1 : xh2;
yl = (yl1 < yl2) ? yl2 : yl1;
yh = (yh1 < yh2) ? yh1 : yh2;
return true;
}
Definition at line 45 of file rpolygon.h.
Copyright © 2007-2010 by The Shadowrun: Awakened Team. This work is licensed under the GNU Lesser General Public License 3.