Indeed; jump points are a special case, in the sense that if we do what safemode was suggesting, of actually simulating a wormhole, this would take a snazzy vertex shader, not just a fragment shader. But we shouldn't go crazy; Hellcat is adamantly opposed to shader proliferation, and for good reasons: shader switch overhead, which is huge; and the problem of maintaining multiple shaders. But some specialized shaders are inescapable. Specially planets.ace123 wrote:Would it be possible to add a "shader" column to units.csv? That way the planet entries in there can have a custom shader.
If klauss has a solution that is also fine... it would be cool to allow custom shaders for some units (For example jump points).
Now, the idea of putting a shader column in units.csv suits me just fine. I think eventually we'll need Klauss' Method thing, but if we can get the units.csv thing to happen faster, I'm all for it. Tons of stuff is NOT happening in the art department because most artists out there don't know how to produce or use bakings. Having a shader column would allow us to switch to having ambient occlusion in the glowmap's alpha channel, and do all the ao dependent calculations in the shader; so models could be updated by just baking the ao and adding it to the glow texture; and changing the shader for it in units.csv. Same with shininess. Shininess computation from specularity doesn't work; but I have a Blender noodle that does a fairly good job of getting a basic shininess map from diffuse AND specular color.
So, yeah, then maybe this idea would remove the urgency for the Method thing, and Kluss could try and get the Tangents to work, first. That would be wonderful, because that's the other thing that's never going to happen in the Arts department: Normalmaps. It's impossible to work on normalmaps with the restriction that front must be North in the texture. Impossible. Well, with a new ship it IS possible, because one is doing a brand new unwrap; but there's no texturers out there that can take an existing mesh and reorient all the UV islands. None. Texturers are not modelers; and even for modelers that's a huge job. We need Tangents yesterday. I mean, a year ago.
By the way, rather than "shader", the column should specify a texture packing version; as shaders may evolve independently of the texture packing version; but what really matters, for shader compatibility, is the texture packing philosophy.
Version 0 (current) has nothing special
Version 1 has shininess in spec alpha.
Version 2 has shininess in spec alpha, and ambient occlusion in glow alpha.
Version 3 has shininess in spec alpha, ambient occlusion in glow alpha, and a "is_dielectric" bit in damage alpha (to turn on Fresnel).
And so on.
Planets and jump points would have special texture packings, so they'd be covered by this system.