Jump to content

shadmar

Members
  • Posts

    3,618
  • Joined

  • Last visited

Everything posted by shadmar

  1. float slope = 1.0-ex_normal.y; vec4 g1=texture(texture0,ex_texcoords0*42); vec4 g2=texture(texture1,ex_texcoords0*42); vec4 g3=texture(texture2,ex_texcoords0*42); vec4 g4=texture(texture3,ex_texcoords0*42); vec4 g1full=texture(texture0,ex_texcoords0); vec4 g2full=texture(texture1,ex_texcoords0); vec4 g3full=texture(texture2,ex_texcoords0); vec4 g4full=texture(texture3,ex_texcoords0); g1=mix(g1,g1full,0.2); g2=mix(g2,g2full,0.2); g3=mix(g3,g3full,0.2); g4=mix(g4,g4full,0.2); outcolor = g1; outcolor = mix(outcolor,g2,smoothstep(0.0,0.05,slope)); outcolor = mix(outcolor,g3,smoothstep(0.01,0.125,slope)); outcolor = mix(outcolor,g4,smoothstep(0.125,0.26,slope));
  2. this is a 4 texture splat shader no normals form LE3 before terrains:
  3. Not sure you can allocate 13 channels? (4 diffuse, 4 normal, 4 specular + 1 for alpha), can't test right now. Might work if you pack specular into the alpha channel of the normal texture, then you would need only 9. (4 color, 4 normal with specular as alpha) + one mask alpha.
  4. Seems to be dead (dropbox killed it) Here it is (again unchanged have idea if it works) : https://www.dropbox.com/s/1oui1t1b6zyxbs9/DayNightCycle_GodRays.zip?dl=0
  5. shadmar

    PBR update

    Looking great Mattline!
  6. This has been asked before, and I don't think you can change by code. But for workaround I think you can do one of these: 1. add an invisible csg box and set it as parent to the model. (not enteirly sure, cant test this atm) 2 .add 8 single verts representing your aabb in the modeler and resave, no faces needed.
  7. Trying to make wet blood stains but, fragData2.a seems to have no effect on decal specular rendering. Blood looks like plastic with no specular, is this a bug?
  8. You could use env probes, and or SSR
  9. assign rendertarget texture to a material and apply material to the monitor/brush/model
  10. There is an tesselation shader shipped with leadwerks, diffuse+normal+specular+tessellation.shader
  11. Bone scaling can also use to create diversity like bigger hands, feet, longer arms, bigger head etc.
  12. I know several swedish jokes
  13. they don't do for... loops so if you unpack the loops into actual statements it should work.
  14. Maybe it's old news, but here they are listed for grabs: https://github.com/LeeBamberTGC/FPS-Creator-Classic
  15. vertex shader of all shaders under Shaders/Model/Animated/* mat3 nmat = mat3(entitymatrix); should be: mat3 nmat = mat3(entitymatrix * animmatrix); You can clearly see the difference when playing animations, normals will now update with the animation.
  16. Checkout GetFace() http://www.leadwerks.com/werkspace/topic/14455-getting-brushes-surface/page__hl__getface#entry98872
  17. Hi We have day and night cycle going in our game, and when the sun is getting really low, the shadows covers vast areas massivly increasing batch count and polycount and we get a huge amount of fps drop, 50% Is there a way to set shadow-range on low angles? Turning shadows off on low sunset/rise is very intrusive visually. Here you can see the difference on middle of the day, and just before the sun sets. Same scene, but light angle is different:
  18. Great, bugsquashing!
  19. shadmar

    Common Bottlenecks

    snippet for setting viewrange based on AABB radii --optimize scene place objects in viewrange based on their aabb radius. for i=0,world:CountEntities()-1 do if world:GetEntity(i):GetClass()==Object.ModelClass then local aabb=world:GetEntity(i):GetAABB(Entity.GlobalAABB) if aabb and aabb.radius < .1 then world:GetEntity(i):SetViewRange(0) elseif aabb and aabb.radius < 1 then world:GetEntity(i):SetViewRange(1) elseif aabb and aabb.radius < 10 then world:GetEntity(i):SetViewRange(2) elseif aabb and aabb.radius < 20 then world:GetEntity(i):SetViewRange(3) else world:GetEntity(i):SetViewRange(4) end end end
  20. reboot seems to fix it. nothing to se here..
  21. first time for everything I guess, never seen this on my GTX 770: Syncing Workshop Items... Error: GetFileInfo failed. (15) Initializing OpenGL4 graphics driver... OpenGL version 110 GLSL version 0 Device: GDI Generic Warning: OpenGL 210 or GLSL 120 are not supported. Failed to initialize graphics. Please ensure your graphics hardware is compatible and install new graphics drivers.
×
×
  • Create New...