-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature implementation: emissiveMaterial() #3820
Conversation
is this really the direction we want to go, though. i would rather move away from the current practice of overloading the fill color, and toward a more reasonable color model like the one that processing uses where the material has different color properties (ambient, emissive, specular) that all contribute separately to the lighting of the surface. this is much more in line with similar color models that are used in other libraries and 3d modeling/rendering packages. |
@Spongman I wouldn't call it overloading, but overwriting, and I also opened an issue regarding this #3806. It would require a lot of refactoring of both shaders and the js part. The shaders themselves are in pretty bad shape right now, and given only one material type is to be rendered, @aferriss and I agreed on this implementation. |
oh, i'm sorry, i didn't realize that it had been decided. i would have like to have weighed in beforehand. can you point me to the issue where that discussion occurred? |
@Spongman I think the issue Sanket is referring to is the one he referenced (#3806) but we didn't get any feedback regarding how to move forward. Since we're on a tight timeline for GSOC we decided it would be best to move forward in the paradigm that was already established (as far as we could tell) in p5 of one material type per geometry. I think we'd both like to eventually add the ability to use multiple material properties per geometry but since it was a much larger task we decided to punt and try to implement at the end of the summer if we had any leftover time. |
yeah, i definitely think this area could use some more discussion before introducing these API changes. for example:
|
@Spongman Are you asking why they are named As for how this is different than basic.frag, it's not. However I think it makes sense to have this kind of redundancy for setting the color of 3d geometry. I feel like in the context of 3d graphics, |
I agree with @aferris here. Restating points differently or offering my extended thoughts, I think that And as far as naming, I actually like |
Going to merge this as I haven't heard any other dissenting opinions. |
@aferriss i find your explanation above to be wholly unsatisfying. now we have two apis for doing essentially the same thing, complicating and confusing the documentation, and i feel this was entirely rushed through with insufficient thought. |
@Spongman I'm sorry to hear that. I felt that the PR was in good shape and that there had been sufficient explanation as to the design and intention of the feature. It seemed to me that enough time had passed and since I hadn't heard from you since I was inclined to merge. I'm happy to continue the discussion if you have further thoughts. |
@Spongman luckily no change is permanent! Open-source software is something that changes with time and not in a strictly unidirectional or linear fashion, so let's not exaggerate the severity of any one decision. I think everyone here is happy to talk if you feel like the merits of this design direction should still be discussed. For my part in said discussion, I wouldn't say this complicates and confuses the documentation or render pipeline. I do think that there is some confusion but that is because this is only one step towards a more fully realized change in which Perhaps there is an opportunity for an innovation in design here but it can only be reached through suggestions and discussion. |
@Spongman could you send me an email at the address listed in my profile? I’d be grateful for the opportunity for a more direct conversation outside of the repo. We could discuss any concerns about the way that decisions are made with the library and also talk about what the expectations are for engaging with the community. One-on-one communications seems ideal for the task. Thanks! |
Implemented emissiveMaterial()
Work done-
uEmissive
uniform in both shadersemissiveMaterial()
in /src/webgl/material.jsTo do-
@aferriss