2431 Commits
Author SHA1 Message Date
Mr.doob 1914458738 Simplified and clarified hierarchy2 example. 2011-10-25 07:34:49 +02:00
Mr.doob a7c804b817 Updated builds. 2011-10-25 06:50:15 +02:00
Mr.doob ed67da2783 Merge remote-tracking branch 'zz85/master' into dev 2011-10-25 06:39:53 +02:00
Mr.doob 5916682ea6 Reverting again
Actually, this would break cameras added as childs of objects, reverting.
So there is no clear and simple way to handling multiple scenes unfortunatelly.
Encouraging `scene.add( camera )` seems like the right thing to do then, less problems.
2011-10-25 05:59:13 +02:00
Mr.doob 13e4f78a28 Reverting my thought
Actually, I think this can be handled magically instead of requiring understanding of the concept that the camera is part of the scenegraph.
While I was at it, I fixed it so you can use a camera for rendering different scenes (the renderer will add it and remove from each scene graph)	.
2011-10-25 05:47:13 +02:00
Mr.doob d902ca3bf0 Updated builds and tweaked examples
Removed LOD text example. I think LOD example is good enough.
Ubiquity test working again.
Tweaked README to show the new pattern (Scene first thing created).
2011-10-25 01:50:17 +02:00
Mr.doob 212506bce4 Merge remote-tracking branch 'alteredq/dev' into dev 2011-10-25 01:18:47 +02:00
Mr.doob 747b813bcb Merging with @alteredq's branch 2011-10-25 01:18:31 +02:00
alteredq ea26fef013 Fixed Collisions.
Fix was trivial, I guess for the moment they can stay.
2011-10-24 18:55:07 +02:00
alteredq cbef41e251 Fixed multi-canvas circle example. 2011-10-24 18:47:45 +02:00
alteredq 9433bd1446 Got ParallaxBarrierWebGLRenderer working. 2011-10-24 18:34:40 +02:00
alteredq eda6d2adde Got AnaglyphWebGLRenderer working.
Hope so ... looks kinda ok, don't have red-blue glasses.
2011-10-24 18:25:02 +02:00
alteredq 609c8c7212 More correct LOD handling (thanks to @mrdoob for insight). 2011-10-24 15:41:11 +02:00
alteredq 9f7f8fd015 Half-baked LOD attempt.
This doesn't handle properly order of updates of LOD vs camera.
2011-10-24 15:19:59 +02:00
Mr.doob e54f2e32e7 Updated builds. 2011-10-24 14:43:33 +02:00
alteredq b2b7282fcd Got skinning working again.
Code is a horrible mess but at least it works. Anyways, some day we should revisit GPU accelerated skinning with a proper pipeline.
2011-10-24 14:33:34 +02:00
Mr.doob fde298e156 Merge remote-tracking branch 'alteredq/dev' into dev 2011-10-24 14:29:47 +02:00
Mr.doob af2919bc17 Adding RenderableObject once again.
It's going to be handy for the WebGLRenderer (__webglObjects)
2011-10-24 14:23:12 +02:00
alteredq 408c82d306 Got WebGLRenderer working again.
I had to resurrect parts of old code (keeping track of scene graph changes).

Good news: performance is great, new scene graph gains compound with buffers optimizations and non-array materials refactoring. Together we gained about 15% for rotating cubes performance test (pushing max to 2650 cubes at 60 fps).

Still broken with new scene graph: lod, skinning, collisions, AnaglyphWebGLRenderer, ParallaxBarrierWebGLRenderer, multi-canvas circle example.
2011-10-24 12:30:04 +02:00
zz85 f39c58b79b Replace THREE.ScaleModifier with geometry.applyMatrix 2011-10-24 10:42:35 +08:00
Mr.doob caabab07f3 Lines can be treated as Objects 2011-10-23 14:18:57 +02:00
Mr.doob ec00f298be CanvasRenderer and SVGRenderer using single-material system.
Also moved `.overdraw` to Material.
Code is much simpler now :)
2011-10-23 13:50:55 +02:00
Mr.doob 806ecdfc04 Merge remote-tracking branch 'alteredq/experimental_shading_materials' into dev 2011-10-23 12:34:56 +02:00
Mr.doob 6b151b552e Merging with @alteredq's experimental branches. 2011-10-23 12:34:46 +02:00
Mr.doob 20c96f52e9 Reverted changes, starting again. 2011-10-23 10:04:28 +02:00
zz85 2757ae44a9 Merge branch 'master' of github.com:zz85/three.js 2011-10-23 01:29:42 +08:00
zz85 0a444b9d8a ScaleModifier uses geometry.applyMatrix 2011-10-23 01:24:27 +08:00
zz85 973e6156e8 CombinedCamera decouples setFov from perspective mode now 2011-10-23 01:24:27 +08:00
zz85 e17dc71d5b Added ScaleGeometry and added Monkey Head + more geometries to examples 2011-10-23 01:24:27 +08:00
zz85 24dcc76bf7 fix subdivision example 2011-10-23 01:24:27 +08:00
zz85 522fa70a22 Fixed sharp corners for Subdivision Modifier 2011-10-23 01:24:27 +08:00
zz85 ed7fcf7cb3 Update Subdivision model loading 2011-10-23 01:24:27 +08:00
zz85 435cdb9ff7 cleaner way of doing perspective->orthographic 2011-10-23 01:24:27 +08:00
zz85 cfc77699d3 Adding WaltHead back to subdivision example 2011-10-23 01:24:26 +08:00
zz85 a92ee99dab Combined Camera now tries to use Perspective\'s average viewing frustrum for switching to Orthographic view 2011-10-23 01:24:26 +08:00
zz85 fdc911b6fa added zoom + 6 views for CombinedCamera 2011-10-23 01:24:26 +08:00
zz85 056daa25c6 Views for CombinedCamera 2011-10-23 01:24:26 +08:00
zz85 588c2b0a9f ScaleModifier uses geometry.applyMatrix 2011-10-23 01:11:58 +08:00
zz85 60c103648e CombinedCamera decouples setFov from perspective mode now 2011-10-23 00:42:58 +08:00
alteredq 5edfb12697 Added "autoUpdateObjects" flag to WebGLRenderer.
This is to be able to skip redundant updates in multipass rendering (like for shadow maps or dynamic cube maps).

Also reshuffled initWebGLObjects calls to have just a single update in a basic scenario of shadow map pass followed by scene render.

Still need to solve somehow potential redundant updates in EffectComposer (which can mix multiple scenes).
2011-10-21 18:12:05 +02:00
alteredq 103154d293 Removing some cruft in WebGLRenderer. 2011-10-21 16:25:26 +02:00
alteredq 965b199de2 And some more strict equality checking. 2011-10-21 14:13:44 +02:00
alteredq f166079dcc More strict equality checking.
Just for the sake of consistency, when object properties are not involved performance difference is negligible.
2011-10-21 13:42:28 +02:00
alteredq b410a7804a Small change in setObjectFaces.
These little buggers were costing 3.35% of the total time in performance test.
2011-10-21 13:05:07 +02:00
alteredq b0aae55ed8 Cleaned up a bit buffers handling in WebGLRenderer. 2011-10-21 11:17:05 +02:00
alteredq 81b60ea2f6 All WebGL examples working with array-less materials.
Noticeable difference: can't anymore assign Material references to faces directly - "face.materials" became "face.materialIndex". Materials have to go to "geometry.materials" array (to which "face.materialIndex" points). This is necessary to allow run-time changing of face materials (this indirection used to be done by arrays).

Some casualties:

- multi-materials example, this functionality isn't possible anymore
- had to simplify LOD Text examples as LODs don't handle groups (used to fake multi-materials)
- multi-materials sphere in materials example can't have faces with undefined materials (this may be fixable I guess, when there'll be some real use-case)
- scene format still has materials arrays, only the last material will be used (except when there are face materials, then materials from JSON will be used, as before)

Other renderers and their corresponding examples were not touched yet.

WebGLRenderer still needs some prettification, some things don't make sense anymore without arrays, code can be cleaned up further.
2011-10-21 06:18:59 +02:00
alteredq 05b3db4dca Experimenting with array-less materials.
Do not use for anything, this is just snapshot of a test in progress. I solved quite a few issues, but many things are still clumsy and broken.
2011-10-21 03:06:06 +02:00
alteredq 32ba5a562a Blender exporter seems to work fine with new Blender 2.60 ;) 2011-10-20 22:26:44 +02:00
alteredq b4f89f4b78 Experimenting with Phong computed fully in fragment shader. Added new point lights test.
New per-pixel Phong code is enabled by setting `perPixel` parameter in Phong material.

This version is able to light single untesselated quad correctly.

Also it doesn't have point lights number limitation caused by varyings, all lights pass just through uniforms.

Performance wise it seems surprisingly quite similar to old version (stress test is ~6 fps faster with new version, though I guess for different use cases / GPUs it can differ).
2011-10-19 02:11:44 +02:00
alteredq 2253592365 Added "metal" parameter to Phong. Added new materials test.
Metal makes specular term multiplicative (default is additive). This is to be able to have textured materials that do not have diffuse color, just a specular one, to get metallic look (additive specular gives plastic look).
2011-10-18 16:05:03 +02:00