Hi Vega!
As from programming point of view I would like to enquire about how does vegastrike deals with the coordinates of objects in spece? I mean if I calculate everything in "km" it will take a lot of cpu time. If I calculate everything in a.u. it wount be precise. Still I need to be precise near some objects (orbital bases, for ex.) so I sould use even meters, but I do not need them far away in space.
What tricks do you use to make orientation precise and less cpu-hungry?
P.S. Happy new year!
Space and scales
-
- Just a tourist with a frag'd nav console
- Posts: 3
- Joined: Tue Jan 02, 2007 11:08 am
- Contact:
-
- The Shepherd
- Posts: 5841
- Joined: Fri May 13, 2005 8:37 pm
- Location: Ottawa
- Contact:
Welcome KayT check any of the .system files they are XML i believe that the units used are meters.
Enjoy the Choice
Enjoy the Choice
my box::HP Envy i5-6400 @2Q70GHzx4 8 Gb ram/1 Tb(Win10 64)/3 Tb Mint 19.2/GTX745 4Gb acer S243HL K222HQL
Q8200/Asus P5QDLX/8 Gb ram/WD 2Tb 2-500 G HD/GF GT640 2Gb Mint 17.3 64 bit Win 10 32 bit acer and Lenovo ideapad 320-15ARB Win 10/Mint 19.2
Q8200/Asus P5QDLX/8 Gb ram/WD 2Tb 2-500 G HD/GF GT640 2Gb Mint 17.3 64 bit Win 10 32 bit acer and Lenovo ideapad 320-15ARB Win 10/Mint 19.2
-
- Just a tourist with a frag'd nav console
- Posts: 3
- Joined: Tue Jan 02, 2007 11:08 am
- Contact:
-
- Minister of Information
- Posts: 1895
- Joined: Fri Jan 31, 2003 9:40 pm
- Location: The land of tenure (and diaper changes)
-
- Elite
- Posts: 7243
- Joined: Mon Apr 18, 2005 2:40 pm
- Location: LS87, Buenos Aires, República Argentina
Ya, the main trick is noticing that only unit positions need high precision, orientations, local coordinates (like mountpoints and stuff), need not be like that. In fact, even collision detection ends up working on single precision since the most intensive part is object-against-object, which is done in the local coordinate space of one of the objects, which no longer needs the full precision.jackS wrote:Relative distance calculations tend to use single precision IEEE754 floating point numbers, where possible, for performance reasons.
But... there has been the occasional occurrence of someone mistaking a place that needed double precision for one that didn't, resulting in rounding errors - the code in that way optimized (singles when possible, doubles when needed) is very hard to mantain, as you have to carefully anlyze any change - nightmarish.