summaryrefslogtreecommitdiffstats
path: root/o3d/samples/particles.html
Commit message (Collapse)AuthorAgeFilesLines
* Fixing bug #152 (pressing "T" doens't leave a trail in the particle samples ↵vangelis@google.com2009-09-261-2/+2
| | | | | | | | | | | | only in Chrome). The problem had to do with the translation of the key codes. There's another issue that surfaced with the event.js code in IE when the events are handled by methods running in V8. In that situation it appears that event.keyIdentifier isn't actually a string and IE barfs when we call keyIdent.indexOf(). I added a check to make sure it's a string but I don't know if the fix really belongs somewhere in the V8 / IE bridge Review URL: http://codereview.chromium.org/218002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27308 0039d316-1c4b-4281-b951-d872f2087c98
* Update samples to use more utility functions wheregman@google.com2009-09-011-22/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | appropriate. A few places used pseudoRandom. That is in math.js now so they use that. Other places there is now o3djs.material.createBasicMaterial and o3djs.material.createMaterialFromFile that save 10-20 lines per sample. This CL will require new reference images. There are 2 other things I'd like to consider. #1) Changing every sample that uses shaders/texture-only.shader to use o3djs.material.createConstantMaterial or some variation. The problem with o3djs.material.createConstantMaterial is it requires you pass it a texture if you want a constant textured material. All the samples create the material first, then later add the texture. So, I could add a new o3djs.material.createTextureOnlyMaterial. At the same time that would mean changing those samples from setting stuff on 'texSampler0' to 'emissive' #2) I'd like to change the shader builder so it stops adding "Sampler" to textured materials. As it is if the material uses a color it makes the param called "diffuse" but if it's a texture it makes it "diffuseSampler". That sucks because it means the code has to do crap like var param = material.getParam('diffuse'); if (param) { // it's a color } else { param = material.getParam('diffuseSampler'); if (param) { // it's a texture. } } If we stopped that silliness we could just do var param = material.getParam('diffuse'); if (param) { if (param.isA('o3d.ParamTexture')) { // it's textured. } else { // it's not. } } Unfortunately to fix this requires changing the o3dConverter as well since it uses those conventions. Should we do this? Review URL: http://codereview.chromium.org/182024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25015 0039d316-1c4b-4281-b951-d872f2087c98
* Change <script id="o3d" to <script id="o3dscript"gman@google.com2009-07-281-1/+1
| | | | | | | | | so that document.getElementById('o3d') will work for finding the o3d div. Review URL: http://codereview.chromium.org/159556 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21924 0039d316-1c4b-4281-b951-d872f2087c98
* This change fixes the issue that if you usegman@google.com2009-07-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | o3djs.util.setMainEngine(...V8) in any sample and you use scripts that you don't want run in V8, for example Adsense, Google Analyitics, Wave, Google WebElements then the o3djs would attempt to pull in that javascript and execute it in V8. Specifically this refers to inline <script> tags instead HTML. Not <script src="url"> tags. The solution is we add an id to the tags we want o3djs to pull in. Any script with an id that starts with "o3d" will get pulled in. This CL changes our samples to have that id on their script tags. Review URL: http://codereview.chromium.org/159339 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21585 0039d316-1c4b-4281-b951-d872f2087c98
* Add Google IO sample.gman@google.com2009-07-101-1/+1
| | | | | | Review URL: http://codereview.chromium.org/149438 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20437 0039d316-1c4b-4281-b951-d872f2087c98
* Fix particle sample for IEgman@google.com2009-06-301-3/+3
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19566 0039d316-1c4b-4281-b951-d872f2087c98
* Added particle trails for things like exhaust on a car.gman@google.com2009-06-291-2/+104
| | | | | | Review URL: http://codereview.chromium.org/125189 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19549 0039d316-1c4b-4281-b951-d872f2087c98
* Undoing gcl bug damage AGAINgman@google.com2009-06-171-104/+2
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18600 0039d316-1c4b-4281-b951-d872f2087c98
* adding svn:ignore properties to ignore .o3dtgzgman@google.com2009-06-171-2/+104
| | | | | | | files as well as scons-out etc... git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18599 0039d316-1c4b-4281-b951-d872f2087c98
* Undoing gcl bug damagegman@google.com2009-06-171-104/+2
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18598 0039d316-1c4b-4281-b951-d872f2087c98
* Adds a bunch of svn:ignore properties so that svn statusgman@google.com2009-06-171-2/+104
| | | | | | | doesn't show stuff we don't care about. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18595 0039d316-1c4b-4281-b951-d872f2087c98
* This is the O3D source tree's initial commit to the Chromium tree. It gspencer@google.com2009-05-271-0/+497
is not built or referenced at all by the chrome build yet, and doesn't yet build in it's new home. We'll change that shortly. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17035 0039d316-1c4b-4281-b951-d872f2087c98