asarium
d64196eff0
Refactor tracing subsystem
...
The new design is centered around the Event Trace JSON format but it
should still be possible to adapt it for other profiling tools. The old
profiling system has been removed.
2016-11-24 10:26:21 +01:00
Goober5000
d9c9647919
Merge pull request #947 from MageKing17/cleanup/miscellaneous
...
Some miscelleaneous cleanup commits.
2016-09-17 23:15:17 -04:00
asarium
26f45732da
Move profiling functions into separate folder
2016-09-14 12:26:53 +02:00
MageKing17
bce17561ed
Change pointless .size() calls into .empty() calls.
...
The codebase had quite a few instances of .size() being called and then checked to see if it was 0 or not (or less than 1, or greater-than-or-equal-to 1, which are basically equivalent), when .empty() could be called instead (negated or not, depending on what the original condition was).
2016-09-07 18:36:12 -07:00
asarium
1a212868a0
Add support for outputting profiling data as JSON
...
This output is compatible with the Chromium tracing viewer which
provides a very nice visual overview of what FSO does in a frame.
2016-08-29 20:18:51 +02:00
Fabian Woltermann
127976cd74
Weapon info flags conversion ( #851 )
2016-08-18 23:17:41 -07:00
asarium
0a7800d3ea
And another batch of warning fixes
2016-08-15 18:55:35 +02:00
Fabian Woltermann
770fce8de5
Bitset flags -- take 2 ( #775 )
...
This introduces a new mechanism for handling bit flags. Instead of using an int (or two, or three) to write bits into, this uses the std::bitset in a wrapper class that accepts an enum class as input. This means that certain classes of errors we've had a few of in the engine, where a coder used the wrong set of flags or checked them against the wrong variable (SF_STEALTH vs SIF_STEALTH, for example) can now be detected at a compiler level rather than not at all.
2016-08-12 16:13:50 -07:00
asarium
7b352e511c
Add new memory tracking subsystem
...
This expands the existing system which only worked on Windows to all
supported platforms.
If the MSVC debug runtime is not present then its behavior is emulated
by adding a header to each allocated memory block.
2016-07-29 11:02:45 +02:00
MageKing17
54e052bc2f
Don't assume non-turning weapons have a fixed velocity.
...
Somewhat related to PR #528 , this changes the branch that assumes constant velocity from checking for an absence of the WIF_TURNS flag to checking for the presence of the PF_CONST_VEL flag (because non-turning weapons can be given an acceleration time).
2016-01-31 18:54:41 -08:00
MageKing17
37a98b8cf8
Check B->parent_sig before checking B->parent in objcollide.cpp.
...
Could cause problems with recycled objects (specifically, I had a crash once because "Objects[B->parent].instance" was well over MAX_SHIPS due to being a weapon instead of a ship, causing the "Ships[Objects[B->parent].instance].team" reference to fail hard).
2016-01-26 23:59:23 -08:00
The E
a413255728
Renaming vm_vec_dotprod to vm_vec_dot
2015-12-01 20:35:47 +01:00
Goober5000
5fb98551c9
collision optimization: two objects which do not move will never collide with one another
2015-09-21 16:30:19 -04:00
Goober5000
bd3cd7eb18
Merge pull request #195 from Echelon9/fix/sort-uniq-includes
...
Review and refactor #include's
2015-08-19 00:05:02 -04:00
Echelon9
cd503fd2e4
Fix: object/objcollide.cpp:1247:8: warning: variable ‘max’ set but not used [-Wunused-but-set-variable]
2015-07-04 16:10:15 +10:00
Echelon9
e7e046f949
Fix: object/objcollide.cpp:1248:8: warning: variable ‘overlap_min’ set but not used [-Wunused-but-set-variable]
2015-07-04 16:08:40 +10:00
Echelon9
c5493bb480
Scripted sort and uniq on (internal) project includes. Improves search time and as a by product removed a number of duplicative includes.
2015-06-22 20:24:30 +10:00
asarium
189f23a341
Change SCP_hash_map to SCP_unordered_map
...
Also uses std::unordered_map on every platform now
2015-05-16 11:40:10 +02:00
m_m
de57f043da
From MageKing17 and me: Fix for Mantis 3128: Docking related crash - dock_list isn't initialized This patch makes the copy constructor and the assignment operator of the object class private as it contains members that should not be copied.
...
git-svn-id: svn://svn.icculus.org/fs2open/trunk/fs2_open@11170 387891d4-d844-0410-90c0-e4c51a9137d3
2014-11-08 10:57:03 +10:00
m_m
bd602cc1a3
Revert 11158 as it breaks FRED compilation.
...
git-svn-id: svn://svn.icculus.org/fs2open/trunk/fs2_open@11159 387891d4-d844-0410-90c0-e4c51a9137d3
2014-10-27 18:23:02 +10:00
m_m
89cd36a242
Fix a crash reported by Axem related to freeing the dock list of an object. This was caused by freeing the dock list from the destructor of an object which meant that copies of an object would corrupt the original object instance. To make sure that doesn't happen again the copy constructor and assignment operator of object have been made private.
...
git-svn-id: svn://svn.icculus.org/fs2open/trunk/fs2_open@11158 387891d4-d844-0410-90c0-e4c51a9137d3
2014-10-27 18:23:02 +10:00
Echelon9
b2231f28d1
Fix Coverity 1102734 Uninitialized scalar field: In collider_pair::collider_pair(): A scalar field is not initialized by the constructor (CWE-457). From Flaming_Sword.
...
git-svn-id: svn://svn.icculus.org/fs2open/trunk/fs2_open@10386 387891d4-d844-0410-90c0-e4c51a9137d3
2014-02-02 10:52:50 +10:00
Goober5000
26f8b5fed1
make collider_pair an actual class since its constructor is called by hash_map
...
git-svn-id: svn://svn.icculus.org/fs2open/trunk/fs2_open@9891 387891d4-d844-0410-90c0-e4c51a9137d3
2013-10-07 20:02:31 +10:00
Goober5000
7e5b2aee52
turn mc_info into a plain data struct, part 2
...
git-svn-id: svn://svn.icculus.org/fs2open/trunk/fs2_open@9822 387891d4-d844-0410-90c0-e4c51a9137d3
2013-09-26 18:51:36 +10:00
Zacam
0502b4d648
Revert of 9410. Apparently not ready for prime time, what with older compilers that don't seem to understand C++0x types (and complaints about upgrades to enable it), and it apparently (under said compilers) isn't any faster than stdext::hash_set anyway.
2012-12-10 08:23:19 +00:00
Zacam
5f998ff345
Mantis 2746: Fix for geometry batcher, from Valathil. Update for Mac by Echelon9.
2012-12-09 02:59:02 +00:00
Swifty
6dfa635811
Added better object and weapon cleanup code for the new collision detection code when max object and weapon counts are reached.
2012-09-10 05:08:16 +00:00
Swifty
d8d6e86fd6
Collision caching properly resets between missions.
2012-09-10 03:58:14 +00:00
Swifty
c6c12fc251
go_even_faster: Improved collision detection performance by rewriting broadphase and narrowphase testing.
2012-08-11 21:14:53 +00:00
Goober5000
b0af0aa71a
fix for Mantis #2673 , following Valathil's detective work
2012-06-30 23:31:48 +00:00
Echelon9
dc4371680a
Clear a whole set of LLVM warnings - some of these would have caused memory fubars, so should marginally improve stability
2012-01-15 08:08:15 +00:00
The_E
59cbde3d9e
Adds sexps to manipulate a ships' collision groups. If two objects are members of the same collision group, they will not collide with each other.
2011-06-28 08:36:54 +00:00
The_E
083a84feff
Swifty's go-swift stuff. Makes collision detection slightly less insane.
2010-12-22 14:42:21 +00:00
Sushi
8c6895a029
Re-added collision physics, added basic landings support (still needs some work)
2010-09-13 14:27:42 +00:00
Sushi
5704dce248
Fix a bug where additive weapon velocity would sometimes cause primary shots to pass through a target
2010-05-25 16:25:41 +00:00
Wanderer
cd15f39847
lua handled collision groups and lua bitwise ops library
2010-01-05 18:00:01 +00:00
Wanderer
0715c8d504
Change to collision prediction when using additive weapon velocity. Change to allow 'arm_radius' to sue homing position instead of homing object pos as distance measuring point. Allow weapons with arm_radius to count as armed if they collide with intended target.
2009-09-02 08:13:39 +00:00
portej05
719825f80d
The big CVS comment removal. This chops approx. 3.5mb off a full checkout.
...
I've tested this through compiling and through hand checking.
Normalises line endings in ALL files to \n.
2009-06-20 08:08:20 +00:00
Wanderer
e05276ea1e
merge from wanderer branch.
...
option to allow all hitpointed weapons to be hit.
allow 'safe from weapons' time of bombs be set.
2009-05-20 20:11:15 +00:00
Wanderer
c695230883
Fix for mantis 1915 and related collision detection issues
2009-05-09 10:45:04 +00:00
Goober5000
44e03a8fa8
another fix by razorjack... parent is -1 when created by sexp
2007-09-30 22:37:08 +00:00
Goober5000
bd7be99c55
this should really be capitalized
2007-07-28 21:31:11 +00:00
Kazan
4e96074988
Resolve Mantis 1281
2007-07-24 13:04:11 +00:00
Goober5000
3c3416fa3b
the great big duplicate model removal commit
2007-02-20 04:20:38 +00:00
taylor
66bc9102f9
performance optimizations:
...
- fvi_ray_boundingbox() is faster and should be less prone to compiler/optimization/platform specific issues
- clean up or obj_check_all_collisions() which is a good bit faster now
2007-02-10 00:08:59 +00:00
taylor
806027e4e8
various small compiler warning and strict compiling fixes
2006-09-11 01:00:28 +00:00
taylor
44ddf3545c
dynamically allocate object collision pairs
2005-10-17 05:48:18 +00:00
wmcoolmon
754cad0765
Bumped MAX_PAIRS to prevent objects flying through other objects
2005-10-09 01:50:04 +00:00
taylor
7f786136a6
s/vector/vec3d/g, better support for different compilers (Jens Granseuer)
2005-04-05 05:53:25 +00:00
wmcoolmon
2c2a6334db
Big, massive, codebase commit. I have not removed the old ai files as the ones I uploaded aren't up-to-date (But should work with the rest of the codebase)
2005-03-25 06:57:38 +00:00