Author Topic: Shine maps and DXT1  (Read 2797 times)

0 Members and 1 Guest are viewing this topic.

Offline FUBAR-BDHR

  • Self-Propelled Trouble Magnet
  • 212
  • Master Drunk
    • 165th Beer Drinking Hell Raisers
Shine maps and DXT1
Recently doing some nameplates for TBP I was saving shine maps in DXT5 resulting in some rather shiny ships.  After scratching my head I accidentally hit on the problem.  The original shine maps were saved in DXT1 format (verified by looking at the DDS file header).  Everything I've read and been told seems to point that DXT1 can't be used for shine maps.  So now I'm wondering if the shine maps are even doing anything or does DXT1 work for shine maps? 
No-one ever listens to Zathras. Quite mad, they say. It is good that Zathras does not mind. He's even grown to like it. Oh yes. -Zathras

 

Offline Water

  • 210
Re: Shine maps and DXT1
The alpha for a DXT1  pixel is either black or white, no greyscale. So a DXT1 shine map will work fine.

Black alpha = no Environmental mapping

Edit: Changed No to Black
« Last Edit: June 29, 2009, 07:39:25 pm by Water »

 

Offline Vasudan Admiral

  • Member
  • 211
    • Twisted Infinities
Re: Shine maps and DXT1
Don't mistake shinyness for reflectivity - DXT1 shine maps will more than likely have have the Alpha pixel Water talks about set to white, resulting in the effect where your ship is 100% reflective in-game, but with normal shine. Test it in the ship lab if you're unsure by seeing if the look changes when env map is turned on or off.
Get the 2014 Media VPs and report any bugs you find in them to the FSU Mantis so that we may squish them. || Blender to POF model conversion guide
Twisted Infinities

 
Re: Shine maps and DXT1
If I'm not mistaken, no alpha = complete environ mapping
That's cool and ....disturbing at the same time o_o  - Vasudan Admiral

"Don't play games with me. You just killed someone I like, that is not a safe place to stand. I'm the Doctor. And you're in the biggest library in the universe. Look me up."

"Quick everyone out of the universe now!"

 

Offline DaBrain

  • Screensniper
  • 212
    • Shadows of Lylat board
Re: Shine maps and DXT1
DXT1 supports an 1-bit alpha channel. So just make it black and the env mapping will be gone.

Or alter the shaders so it uses another color channel for the env mapping.

I am not 100% sure if FS2 supports the 1-bit alpha channel.
--------------------------------------------------
SoL is looking for a sound effect artist
Please PM me in case you want to apply
---------------------------------
Shadows of Lylat - A Freespace 2 total conversion
(hosted by Game-Warden)
----------------------------------

 

Offline FUBAR-BDHR

  • Self-Propelled Trouble Magnet
  • 212
  • Master Drunk
    • 165th Beer Drinking Hell Raisers
Re: Shine maps and DXT1
Well that's good to know at least DXT1 does do something.  I thought they were doing something but was worried they weren't.  Actually my big fear was that they were all saved incorrectly but thankfully that's not the case. 

I've been using paint.net (yea I know but it works for what I do) and I don't know what the option does but weight color by alpha and DXT1 is what seems to give the same effect as the originals.  What that flag does I have no idea.
No-one ever listens to Zathras. Quite mad, they say. It is good that Zathras does not mind. He's even grown to like it. Oh yes. -Zathras

 

Offline Nuke

  • Ka-Boom!
  • 212
  • Mutants Worship Me
Re: Shine maps and DXT1
1 bit alpha only gives you full env or no env. but at least it lets you pick one or the other. dxt1 should default to no env, but if you get excessive shinys then it defaults to full env. what we really need is a materials system.
I can no longer sit back and allow communist infiltration, communist indoctrination, communist subversion, and the international communist conspiracy to sap and impurify all of our precious bodily fluids.

Nuke's Scripting SVN

 

Offline chief1983

  • Still lacks a custom title
  • 212
  • ⬇️⬆️⬅️⬅️🅰➡️⬇️
    • Skype
    • Steam
    • Twitter
    • Fate of the Galaxy
Re: Shine maps and DXT1
If you tell me which maps need it, I can probably get some DXT5 maps with proper env to them, that aren't mirrors but still offer a bit of a sheen.  Needs a slight reflection, they're mostly metal after all.
Fate of the Galaxy - Now Hiring!  Apply within | Diaspora | SCP Home | Collada Importer for PCS2
Karajorma's 'How to report bugs' | Mantis
#freespace | #scp-swc | #diaspora | #SCP | #hard-light on EsperNet

"You may not sell or otherwise commercially exploit the source or things you created based on the source." -- Excerpt from FSO license, for reference

Nuclear1:  Jesus Christ zack you're a little too hamyurger for HLP right now...
iamzack:  i dont have hamynerge i just want ptatoc hips D:
redsniper:  Platonic hips?!
iamzack:  lays

 

Offline redsniper

  • 211
  • Aim for the Top!
Re: Shine maps and DXT1
Herra says they should be concrete... :nervous:
"Think about nice things not unhappy things.
The future makes happy, if you make it yourself.
No war; think about happy things."   -WouterSmitssm

Hard Light Productions:
"...this conversation is pointlessly confrontational."

 

Offline blowfish

  • 211
  • Join the cult of KILL MY ROUTER!!!!!!!!!!1
Re: Shine maps and DXT1
FS2 will not read DXT1's alpha channel.  When DXT 1 is used (or any format that lacks an alpha channel, for that matter), environmental mapping will be calculated based on the RGB intensity.  For format's like DXT3 and DXT5 which have an alpha channel, that alpha channel will be used.  So if you leave the image fully opaque and save as DXT5, you will get full alpha.

 

Offline Herra Tohtori

  • The Academic
  • 211
  • Bad command or file name
Herra says they should be concrete... :nervous:

Oh what a funny man you are... :lol:

I was talking of the basic underlying structure of something like GTD Orion, not the surface of the ship. Reinforced concrete might not be as silly a building material for a massive space ship as you might think. Provided you can use it where you're building the ship. Using it in vacuum might be slightly problematic.

Regarding DXT1; I was under the impression that FS2_Open does not even read the alpha channel on that format, and when there is no alpha, the engine currently interprets it as black (no alpha). Am I completely in the woods with this assumption of mine?
There are three things that last forever: Abort, Retry, Fail - and the greatest of these is Fail.