1. 29 12月, 2010 4 次提交
  2. 28 12月, 2010 3 次提交
  3. 27 12月, 2010 10 次提交
  4. 26 12月, 2010 10 次提交
    • A
      Resurrected exponential fog as FogExp2. · fb7788f0
      alteredq 提交于
      For the moment, only one type of fog is baked into shader, depending on scene.fog initial value.
      
      If use case arise for dynamic fog type switching, this could be changed, though than both fogs would need to be computed all the time :S.
      fb7788f0
    • A
      Added diffuse map to normal map shader. Changed Lee Perry-Smith demo to use normal map shader. · 6e91de5d
      alteredq 提交于
      Diffuse map and ambient occlusion maps are now optional in normal map shader.
      
      By default, both are disabled, so they need to be enabled explicitly like this:
      
          uniforms[ "enableAO" ].value = true;
          uniforms[ "enableDiffuse" ].value = true;
      6e91de5d
    • M
      Improving fog effect :) · 03c5f0f8
      Mr.doob 提交于
      03c5f0f8
    • A
      Synced with mrdoob's branch. · 91b9539e
      alteredq 提交于
      91b9539e
    • A
      Added clear color parameter to WebGLRenderer constructor, also added setClearColor API call. · 255c042b
      alteredq 提交于
      This allows to work around ANGLE antialiasing issue appearing when compositing WebGL framebuffer with transparent background color with HTML canvas element background (while keeping antialiasing on).
      
      WebGLRenderer constructor now takes JSON object with few optional parameters:
      
          renderer = new THREE.WebGLRenderer { scene: scene,
                                               antialias: true,
                                               clearColor: 0x000000,
                                               clearAlpha: 0 };
      
      Here is how to change clear color in runtime:
      
          renderer.setClearColor( 0xff0000, 1 );
      255c042b
    • M
      That demo wasn't supposed to go in... · b086c2c5
      Mr.doob 提交于
      b086c2c5
    • M
      Added Lee Perry-Smith Normal-notyet-Map demo. · 3993d3d5
      Mr.doob 提交于
      3993d3d5
    • M
      Added Lee Perry-Smith Normal-notyet-Map demo. · 93fa1df1
      Mr.doob 提交于
      93fa1df1
    • M
      Cleaned up CanvasRenderer/MeshDepthMaterial code. · e46346c9
      Mr.doob 提交于
      Moved near/far values from MeshDepthMaterial to Camera (CanvasRenderer/WebGLRenderer/WebGLRenderer2).
      e46346c9
    • M
      WebGLRenderer2: Added env_map (SphericalReflectionMapping). · 0c3e69cc
      Mr.doob 提交于
      Eventually I'll have to continue in the experimental branch. Want to give it a go to the ColorPass/TexturePass material API. The color + map + env_map setup feels too limiting...
      
      Now that I have more knowledge of WebGL and shaders, this is how the ColorPass/TexturePass API looks like:
      
      	var material = [
      
      		new THREE.MeshLambertMaterial( [
      
      			new THREE.ColorPass( 0xff0000, 1, THREE.NormalBlending ),
      			new THREE.TexturePass( new Texture( <image>, new THREE.UVMapping() ), 0.5, THREE.NormalBlending ),
      			new THREE.TexturePass( new Texture( [ <image>, <image>, <image>, <image>, <image>, <image> ], new THREE.CubeRefractionMapping() ), 1, THREE.SubtractiveBlending ),
      			new THREE.ColorPass( 0x0000ff, 1, THREE.AdditiveBlending )
      
      		], { blending: THREE.NormalBlending } ),
      
      		new THREE.MeshBasicMaterial( [
      
      			new THREE.ColorPass( 0xff0000, 1 ),
      
      		], { blending: THREE.AdditiveBlending, wireframe: true } ),
      
      		new THREE.MeshPhongMaterial( [
      
      			new THREE.ColorPass( 0xff0000, 1 ),
      
      		], { ambient: 0x000000, specular: 0xbbaa99, shininess: 50, blending: THREE.NormalBlending } );
      
      	];
      
      Makes things a bit longer but I think it's more intuitive this way (and pretty powerful). However, the simplest material would be like this:
      
      	var material = new THREE.MeshBasicMaterial( new THREE.ColorPass( 0xff0000 ) );
      
      Mhh... Now I don't know whether they should called `*Pass`, or `*Layer`...
      0c3e69cc
  5. 25 12月, 2010 3 次提交
  6. 24 12月, 2010 3 次提交
  7. 22 12月, 2010 1 次提交
    • M
      Added Terrain + Fog demo. · 93d55298
      Mr.doob 提交于
      WebGLRenderer2: Fixed a possible issue when modifying scene parameters and having only one program (thx alteredq)
      93d55298
  8. 21 12月, 2010 6 次提交