40 Commits

Author SHA1 Message Date
Graham Pentheny
5111139558
Fixes for many low-severity compiler warnings (#576)
* Fixes for many low-severity compiler warnings

Mostly a lot of pedantic things like end-of-file newlines and commas on the last enum value.  However some fixes like the weak v-tables warnings fixes might help with code gen.  It's unclear if the linker is able to elide multiple copies of the same type's v-table in different translation units, (sometimes it can) but these fixes ensure we don't have to rely on it.
2022-11-11 21:03:03 -05:00
Maciej Babinski
ba12abead9 Add more constructors. 2018-05-22 13:09:26 +02:00
mbabinski-at-google
9235b4a0c4 Add rcNew/rcDelete, template functions that allocate/deallocate objects using rcAlloc/rcFree. (#324)
Add rcNew/rcDelete, template functions that allocate/deallocate objects using rcAlloc/rcNew.
The intention is to use these to move construction logic out of rcAllocateFooObject/rcFreeFooObject and into constructors/destructors, giving users flexbility in how objects are allocated. In particular, this allows stack allocation.
2018-05-18 15:40:37 +02:00
grahamboree
c9bacf3c9c Unit tests for a good number of Recast functions.
These are by no means complete coverage of the functions they test, but are at least a start.  For consistency, all floating point comparisons use Approx(), regardless of whether they need to or not.

Removed unnecessary C++11 unique_ptr stuff, now that rcHeightfield has a constructor and destructor.
2016-03-29 01:04:51 -04:00
grahamboree
61dbce80e9 Added Constructor and Destructor to rcHeightfield. 2016-03-20 18:42:14 -04:00
Rafael Stahl
6d3c9b38ba add rcScopedTimer to fix timers not being stopped on all paths and to prevent it in the future. 2015-12-18 14:48:31 +01:00
Kromster80
d1bdd8192e Update Recast.cpp 2014-11-13 17:36:22 +03:00
Kromster80
ccc346fd53 Fixed typos 2014-11-13 16:52:10 +03:00
grahamboree
b493e7e6f6 Added rcIngoreUnused which can be called to ignore unused parameters. 2013-10-14 16:32:20 -04:00
Mikko Mononen
e6b1d141d2 Fixed warnings when compiling with -Wshadow. 2012-02-22 17:25:46 +00:00
Stephen Pratt
6f5c9f9b82 Recast: Detail API documentation for the members declared in Recast.h. (Complete)
Recast.h: Completed rcPolyMeshDetail through end, plus updates to existing documentation.
Configuration: Removed DebugUtils directory from the document build.
Configuration: Fixed issue 179. (Backslashes)
2011-08-29 23:03:16 +00:00
Stephen Pratt
5553d19d59 Recast: Detail API documentation for the elements declared in Recast.h. (Partial)
The elements through rcPolyMesh are complete.
2011-08-22 21:49:21 +00:00
Mikko Mononen
1de5e2f119 DETOUR API CHANGE!
- Detour Navmesh supports layers
- Allow to disable Navmesh BV-tree
- Added DetourTileCache
- Cleaned up Recast layer code
- Moved portal edge detection to Recast
- Removed polymesh border offset
- Removed lean heighfield
2011-03-25 09:16:38 +00:00
Mikko Mononen
b6a93f063a Removed layer portals, added cons, which stores connectivity and portals. Layer heights is stored as bytes. 2011-03-11 15:12:15 +00:00
Mikko Mononen
e84d563bfe Added boxmapped texturing to input mesh, helps visualize it better. Added polymesh generation for layered heighfields. 2011-03-06 15:40:33 +00:00
Mikko Mononen
6cb0413cc7 Layer progress: Fixed reg building with multiple areas. Added contour generation. 2011-03-06 08:26:55 +00:00
Mikko Mononen
ce6f2a52fc Fixed mem leaks with layers. Added layer region generation test. 2011-02-27 20:39:17 +00:00
Mikko Mononen
f140c3962d Heighfield Layer progress. 2011-02-26 15:05:21 +00:00
Mikko Mononen
2f47c29336 Added lean heighfield to store minimal, easy to compress representation of the heightfield. Added temporary obstacle demo. 2011-01-14 10:55:37 +00:00
Mikko Mononen
f5c3a8b609 Fix for Issue 128 (third time the charm) 2010-10-10 10:15:44 +00:00
Mikko Mononen
5ba6518ed3 Detour compiles now with DT_VIRTUAL_QUERYFILTER. Fixed typos in comments. Fixed bug in findStraightPath() where leftPolyType was not used. 2010-08-26 18:57:53 +00:00
Mikko Mononen
5abddbf0cd Refactored rcBuildContext to be more customization friendly, changed name to rcContext. 2010-08-24 17:53:38 +00:00
Mikko Mononen
8215cd48d1 - win32 compile fixes
- update vc project
2010-08-19 10:23:58 +00:00
Mikko Mononen
613d61f453 Removed Recast timer and log, added rcBuildContext, improved build time printout, fixed issue 67, issue 77, issue 87 2010-08-19 09:26:55 +00:00
Mikko Mononen
5ebcb453fb Issue 45:Input triangle based area creation (another try) 2010-07-13 07:19:10 +00:00
Mikko Mononen
cd3a351f40 Custom allocator for Recast. 2010-07-09 12:55:14 +00:00
Mikko Mononen
fb369a2efd Removed math.h dependancy from Recast.h, moved sqrtf to Recast.cpp. 2010-07-09 08:45:58 +00:00
Mikko Mononen
fca9709196 fix for issue 85:Make getSpanCount accessible 2010-07-08 11:41:08 +00:00
Mikko Mononen
10b330ffb4 Moved common functions behind name decoration. 2010-04-14 18:45:46 +00:00
Mikko Mononen
193f44a388 Issue 61: take 2, missing files. 2010-04-13 10:58:18 +00:00
Mikko Mononen
5119b5cb16 API CHANGE! Better serialization support. 2010-03-25 12:24:40 +00:00
Mikko Mononen
d9d9fa85a5 Added more bits to compact neighbour indices, moved region id to rcCompactSpan to save memory. 2010-03-05 09:10:13 +00:00
Mikko Mononen
fa66b9a9f3 Compiles with -Wall (except stb_truetype) 2010-02-05 07:32:30 +00:00
Mikko Mononen
9b881bde8c NOTE: Changed the generation procedure, see samples! Erode walkable area before area is generated. Allow to mark areas on chf. Generate regions following areas (+ many fixes here and there to make it alwasy work). 2010-02-01 14:08:06 +00:00
Mikko Mononen
14d1c97f1a Added RC_NOT_CONNECTED which is used to check the return value of rcGetCon() 2009-11-15 11:24:20 +00:00
Mikko Mononen
ed73b46308 - Changed gotos as cleanup mechanism to a scoped delete template.
- Removed unnecessary ptr casts to ints to allow to compile on 64bits systems.
- Added custom and portable qsort_r.
- Use gettimeofday() as performance timer on unix/bsd/osx
- Moved variables from rcCompactSpan to separate arrays.
2009-09-28 09:54:37 +00:00
Mikko Mononen
6de4d30705 Monster update which adds detail height meshes.
- Added detail height mesh generation (RecastDetailMesh.cpp) for single,tiled statmeshes as well as tilemesh.
- Added feature to contour tracing which detects extra vertices along tile edges which should be removed later.
- Changed the tiled stat mesh preprocess, so that it first generated polymeshes per tile and finally combines them.
- Fixed bug in the GUI code where invisible buttons could be pressed.
2009-08-24 12:44:44 +00:00
Mikko Mononen
e638624828 Version 1.2
Removed paris demo code.
Cleaned up the API and added missing comments.
2009-06-16 09:57:55 +00:00
Mikko Mononen
c56ebb7e77 - (too) large refactoring of the generation and demo code to support tiled preprocessing
- added rcFixupAdjacentContours which adjust adjacent contour sets so that that they share all vertices (still buggy!)
- changed the demo stucture to handle tiled navmesh generation process (still ugly)
- the performance results are put into a struct instead of logged immediatelly
- added ChunkyTriMesh class which allows to partiotion a trimesh to smaller pieces using AABB tree
2009-05-17 13:31:09 +00:00
Mikko Mononen
06832c885e Initial commit. 2009-03-29 10:30:52 +00:00