Author Topic: Do we still need $Detail distance?  (Read 2752 times)

0 Members and 1 Guest are viewing this topic.

Offline SF-Junky

  • 29
  • Bread can mold, what can you do?
Do we still need $Detail distance?
Me thinks that this item stems from ancient times when computers had 256 MB of memory and the Intel Pentium II was state-of-the-art CPU crap. Today we all have supercomputers at home. So what speaks against setting detail distance to ( 0 ) for all ships - or at least for everything smaller than a destroyer?

 
Re: Do we still need $Detail distance?
Because anyway you won't see the difference in details at 2km away for fighters in a dogfight. And if it can light the load on the cpu/gpu to do other things then why change this? If you want more details at distance you can still edit the ai profile table and increase the settings of $Detail Distance Multiplier.

 

Offline The E

  • He's Ebeneezer Goode
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
Re: Do we still need $Detail distance?
For fighters? Probably not. For large, 20k-plus polygon capships? Yes, absolutely.
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns

 

Offline zookeeper

  • *knock knock* Who's there? Poe. Poe who?
  • 210
Re: Do we still need $Detail distance?
Me thinks that this item stems from ancient times when computers had 256 MB of memory and the Intel Pentium II was state-of-the-art CPU crap.

Any sane 3D engine supports LODs, its usefulness is by no means limited to obsolete hardware.

 

Offline SF-Junky

  • 29
  • Bread can mold, what can you do?
Re: Do we still need $Detail distance?
Okay, that's three convincing arguments to stick with LODs within three replies. :)

 

Offline Novachen

  • 29
  • The one and only capella supernova
    • Twitter
Re: Do we still need $Detail distance?
Absolutely we need this.

Not only, because there are executables for older consoles of this game for example. Consoles like openPandora, X-Box Classic or even Sega Dreamcast...
Female FreeSpace 2 pilot since 1999.
Former Global moderator in the German FreeSpace Galaxy Forum.
Developer of NTP - A Multi-Language Translation Library Interface, which allows to play FreeSpace in YOUR Language.

Is one of my releases broken or not working? Please send a PM here, on Discord at @novachen or on Twitter @NovachenFS2, a public tweet or write a reply in my own release threads here on HLP, because these are the only threads i am still participating in.

 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
Re: Do we still need $Detail distance?
Absolutely we need this.

Not only, because there are executables for older consoles of this game for example. Consoles like openPandora, X-Box Classic or even Sega Dreamcast...
...What? I'm unaware of anyone running FSO on the Dreamcast or the XBox, and the only port of FSO to the OpenPandora I'm aware of is for TBP, and based on FSO 3.7.0. Even if, for some reason, all future mod releases stopped using detail distance and future versions of FSO started ignoring it, that port would be unchanged, so... :confused:
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 

Offline Mongoose

  • Rikki-Tikki-Tavi
  • Global Moderator
  • 212
  • This brain for rent.
    • Minecraft
    • Steam
    • Something
Re: Do we still need $Detail distance?
For fighters? Probably not. For large, 20k-plus polygon capships? Yes, absolutely.
I think even a few of the MediaVP fighter models are into 5-digit polycounts.

 

Offline Mito [PL]

  • 210
  • Proud Member of Slavicus Mechanicus
Re: Do we still need $Detail distance?
However, this LOD change is really visible, especially when it comes to older HTL models, like the Orion or Fenris. I'm not a coder, but would it be possible to expand the LOD0 range - or even make the LOD change distance treshold dependant on a proper ship table parameter?
How do you kill a hydra?

You starve it to death.

 

Offline Admiral Nelson

  • Resurrecter of Campaigns
  • 211
  • The GTA expects that every man will do his duty.
Re: Do we still need $Detail distance?
You can always override the MVP detail distance values with a small tbm of your own that pushes the detail distance values way out.  I used to do that before the last MVPs.

I will say that Asteroid LODs seem inordinately visible, though.  Probably something to look into there.
If a man consults whether he is to fight, when he has the power in his own hands, it is certain that his opinion is against fighting.

 

Offline Luis Dias

  • 211
Re: Do we still need $Detail distance?
Doesn't this also affect things like collision detection?

 

Offline zookeeper

  • *knock knock* Who's there? Poe. Poe who?
  • 210
Re: Do we still need $Detail distance?
Doesn't this also affect things like collision detection?

Collision detection doesn't use the lower LOD levels, it always uses LOD0. Unless you specifically use the new'ish the $Collision LOD feature, that is.

 

Offline Luis Dias

  • 211
Re: Do we still need $Detail distance?
That's.... something I didn't know. Using LODs to collision detection seemed such a no brainer, but just reading that link I can already understand the list of exceptions and problems you will encounter with such a system.

 

Offline The E

  • He's Ebeneezer Goode
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
Re: Do we still need $Detail distance?
That's.... something I didn't know. Using LODs to collision detection seemed such a no brainer, but just reading that link I can already understand the list of exceptions and problems you will encounter with such a system.

It's an important performance optimization, especially for those 6k poly fighters people make; resolving collisions against LOD0 is really expensive. Furthermore, assuming that the LOD1 (or whatever you want to use) has the same dimensions as LOD0, there's no appreciable difference between hits to LOD0 and LOD1.
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns

 

Offline zookeeper

  • *knock knock* Who's there? Poe. Poe who?
  • 210
Re: Do we still need $Detail distance?
That's.... something I didn't know. Using LODs to collision detection seemed such a no brainer, but just reading that link I can already understand the list of exceptions and problems you will encounter with such a system.

Sure, if the ship has submodel subsystems and turrets and the like, then the LOD to be used for collision detection needs to be built with that in mind. But that can make collision detection a whole lot faster. For example in complex and fancy fighter models a lot of the polycount can simply have been spent making sure all engine cones, gun barrels and round surfaces are nice and smooth, whereas for purposes of collision detection, a gun barrel really doesn't need to be more than 4-sided. Small greebles and grooves don't need to be considered at all.

It's usually a pretty quick job (at least with the mesh editing tools of 3ds Max) to minimize those kinds of details to produce a LOD1 that doubles nicely as a collision mesh.

For really big ships it's harder to make significant savings, so it might normally not be worth the effort.