Impressive how 2 layer materials get properly blended in OpenGl! the fairy material is a bit worrying.
so, It's a patch we should or shouldn't apply?
Techdemo 0.7: Massive Problems
Yesso, It's a patch we should or shouldn't apply?
I also did some rewriting / cleanup of the OpenGLMaterialRenderer. Basicaly what I did is the following:
1) Every MatRenderer enables only the states it needs AND it also only disables those states it previously enabled.
2) When ever a OnSetMaterial method is called the matrenderer calls Driver->setTextutre(.....) which re-sets the textures (hehe)
3) Almost every Renderer now has a implementation of OnUnsetMaterial
If You're interested You may download the changed version here.
- Shadows still don't work
- 2 Layer SOLID doesn't work
Here's another screenshot (thisone should be less scary for afecelis
another screenshot with solid_2_layer material (textures pixel colors = Sum on R,G,B of (Source0-0.5)*(Source1-0.5)
Test it! most of all, test it with different material / node setups then the specialfx demo since i testet with that already.
Last edited by zola on Tue Sep 14, 2004 1:35 pm, edited 1 time in total.
cool. So with your way, zola, the onUnsetMaterial is actually called as niko intended? is that right?
You do a lot of programming? Really? I try to get some in, but the debugging keeps me pretty busy.
Crucible of Stars
Crucible of Stars
-
zola -
@Electron
I didn't change anything regarding to the control flow of the material system so this part is exactly the way Niko planned it and it works very good, if I dare say.
I only changed the OnSetMaterial methods a little and implemented the missing OnUnsetMaterial methods and reset the states that were set previously.
I don't know why these methods were not implemented maybe niko just didn't have the time?
I also must add that I'm in no way an OGL expert. So if anyone finds a better way of dealing with things please do make the changes, especially the LIGHTMAP and the SOLID_2_LAYER materials need some expert work
I didn't change anything regarding to the control flow of the material system so this part is exactly the way Niko planned it and it works very good, if I dare say.
I only changed the OnSetMaterial methods a little and implemented the missing OnUnsetMaterial methods and reset the states that were set previously.
I don't know why these methods were not implemented maybe niko just didn't have the time?
I also must add that I'm in no way an OGL expert. So if anyone finds a better way of dealing with things please do make the changes, especially the LIGHTMAP and the SOLID_2_LAYER materials need some expert work
ok, well your way is better than my little hacked fix, anyway
You do a lot of programming? Really? I try to get some in, but the debugging keeps me pretty busy.
Crucible of Stars
Crucible of Stars
