Git Product home page Git Product logo

philogl's People

Contributors

beizhang avatar drewwells avatar epskampie avatar ih57452 avatar ikarienator avatar pangwa avatar philogb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

philogl's Issues

LIGHT_MAX bug

Make sure you exit the shader light for-loop if the index exceeds the number of lights set.

Improve support for multiple programs

This would include:

  • Creating multiple programs from an array of programs in the PhiloGL constructor function.
  • Make O3D models attached to a program used when rendering those models in particular.

Error on world Flights

http://senchalabs.github.com/philogl/PhiloGL/examples/worldFlights/

Uncaught Error linking the shader: C:\Users\vjeux\AppData\Local\Google\Chrome\Application\13.0.782.1\Shader@0x04DDF408(154,17): warning X3206: implicit truncation of vector type
C:\Users\vjeux\AppData\Local\Google\Chrome\Application\13.0.782.1\Shader@0x04DDF408(89,5): warning X3565: loop simulation finished early, use /O1 or above for potentially better codegen
error X4507: maximum ps_3_0 constant register index (224) exceeded - Try reducing number of constants referenced

Stack Trace:
kPhiloGL.js:75
k.fromShaderSourcesPhiloGL.js:77
k.fromShaderURIs.g.onSuccess.g.onSuccessPhiloGL.js:78
u.send.h.onreadystatechangePhiloGL.js:80

Application API

Some docs on the Application API would be awesome.

Thanks

What should happen when applying opacity less than 1 to a node with descendants?

Hello Nicolas,

I'd like your opinion:

If we have a node in a 3D scene, and it has many descendants (a sub tree), what should happen when we apply opacity with a value less than 1 to it?

  1. It, and all of it's children should become transparent, multiplying opacities down the scene graph.
  2. It's content should become transparent but not that of its descendants.
  3. Same as (1), but the whole object should be flattened into a plane.

The reason I want your opinion is because the new specs for CSS 3D (css-transforms) state here that the answer is (3).

To see what I mean, view these two examples in Chrome 53 or higher:

The second example has opacity applied to the node that contains all the sub-nodes which compose the car. The opacity, according to spec, flattens the car into a plane (turns it into paper!).

I'm asking various 3D engine authors for opinions of what the correct or most expected behavior should be.

All the best,
~ Joe

Quat.fromMat4() bug

Hi developers,

Your definition for Mat4 is (n11, n12, n13, n14, ..., n44).
But, Quat.fromMat4 is written as follows:
...
u, v, and w is one of 0, 1, 2.
...
q[v] = 0.5 * (m['n' + v + '' + u] + m['n' + u + '' + v]) / r;
q[w] = 0.5 * (m['n' + u + '' + w] + m['n' + w + '' + u]) / r;
q[3] = 0.5 * (m['n' + v + '' + w] - m['n' + w + '' + v]) / r;
...

So, it makes a bug, undefined.
for example, if when v=0 and u=1, 'n' + v + '' + u makes "n01" and m["n01"] is undefined.

q[v] = 0.5 * (m['n' + (v + 1) + '' + (u + 1)] + m['n' + (u + 1) + '' + (v + 1)]) / r;
q[w] = 0.5 * (m['n' + (u + 1) + '' + (w + 1)] + m['n' + (w + 1) + '' + (u + 1)]) / r;
q[3] = 0.5 * (m['n' + (v + 1) + '' + (w + 1)] - m['n' + (w + 1) + '' + (v + 1)]) / r;

maybe right.

Make Grouped XHRs

By sending an array of urls instead of just one url.

var req = new PhiloGL.IO.XHR({
  url: ['url1', 'url2'],

  onSuccess: function(arrayOfResponses) {

  },

  onError: function() {
    alert("An error ocurred");
  }
});

Use this when loading vs and fs. Parallel request will give faster loads.

Lesson 11 mouse inversion

This isn't anything critical, but I figured I'd report it at least.

Compare the effect click-and-drag has on the original Learning WebGL demo with PhiloGL:

http://learningwebgl.com/lessons/lesson11/index.html
http://senchalabs.github.com/philogl/PhiloGL/examples/lessons/11/

  1. Rotate the moon 90 degrees about its initial vertical axis.
  2. Click-and-drag up and down.

In the original, the up-and-down motion rotates the moon about the viewport horizontal axis. In the PhiloGL demo, the up-down drag rotates about the original model horizontal axis (whic is no longer aligned with the viewport).

PhiloGL should not be globally bound to a single canvas

It seems that PhiloGL is limited to a single instance rendering context in the moment due to it's use of the global gl object. This was not my intuition and should probably not be the case

I think we might be able to refactor the gl object to be per-instance and solve this issue but I'm still learning the PhiloGL code base. Can someone confirm if this is the case?

Use Case: my application. I need to render 2 WebGL contexts simultaneously.

See https://github.com/senchalabs/philogl/blob/master/src/core.js#L56

Include lessons in the build.

For the next build, the entire code for the shaders and other resources for the lessons should be shipped. Make sure there's a readme explaining where all resources come from.

Enhance typed Array integration

By ensuring all vertices, normals, texCoords, indices use typed arrays. Maybe also consider true getters and setters for colors, vertices, normals and other properties so we can ensure they're typed arrays in the correct format.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.