ulf.schroeter Posted August 30, 2012 Share Posted August 30, 2012 Specialized material for rendering of anti-aliased thin geometry like wires, antennas, street markings as described under http://www.humus.nam...?page=3D&ID=89. I am sure that EVERY virtual world customer will love such a material (best-case including corresponding shadow map material !) as thin-line aliasing/shimmering both of the geometry itself and it's shadows is one of the most disturbing and uncontrollable artifacts e.g. in typical urban environments. Link to comment
manguste Posted September 13, 2012 Share Posted September 13, 2012 Added to a wish-list. Link to comment
ulf.schroeter Posted September 15, 2012 Author Share Posted September 15, 2012 Wow frustum, that was quick ! This vertex-shader solution seems to use a different approach than the (DX10+ only?) pixel-shader base one of HUMUS with blending. Is there any drawback ? And what is the magic behind #ifdef WIRE float radius = max(getPosition(vertex).w * s_viewport.w / s_projection[1].y,0.0f); vertex.xyz += normal * radius; #endif Does this ensure that mesh vertices stay always at least 1 pixel away after projection to screen space ? Link to comment
frustum Posted September 16, 2012 Share Posted September 16, 2012 HUMUS wire demo doesn't require DX10 hardware. This code can keep any geometry from zero-pixel collapsing. Blending option is not available because of depth-based post effects like scattering and depth of field. Alpha dithering fade is used instead. Link to comment
ivan.cuevas Posted September 17, 2012 Share Posted September 17, 2012 Can you share the wire_00 sample? Link to comment
frustum Posted September 17, 2012 Share Posted September 17, 2012 Can you share the wire_00 sample? No problem. data.zip Link to comment
ulf.schroeter Posted September 17, 2012 Author Share Posted September 17, 2012 I think <SDK>/data/core/scripts/system.h needs small modification for including the new material too ... void init(string name_,string locale_) { ...... // load materials if(simple_materials) { ..... engine.materials.load("core/materials/simple/unigine_mesh_wire.mat"); } else { ... engine.materials.load("core/materials/default/unigine_mesh_wire.mat"); } .... } Link to comment
frustum Posted September 18, 2012 Share Posted September 18, 2012 I think <SDK>/data/core/scripts/system.h needs small modification for including the new material too Thanks. I forgot to add modified system.h file... Link to comment
Recommended Posts