Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
Home
Help
Search
Login
Register
www.jpct.net
»
jPCT-AE - a 3d engine for Android
»
Support
»
shared shader but unshared uniform parameter?
« previous
next »
Print
Pages: [
1
]
Go Down
Author
Topic: shared shader but unshared uniform parameter? (Read 1767 times)
MichaelJPCT
float
Posts: 267
shared shader but unshared uniform parameter?
«
on:
June 05, 2017, 08:31:36 am »
http://www.jpct.net/forum2/index.php/topic,3965.msg27866.html#msg27866
i search the forum and found the above thread and maybe it's the same question as i have.
i hope to use 1 shader instance for multiple objects but their uniform parameters are different.
is the solution in the above thread the only solution?
is it more troublesome than using 1 shader for each object? is it worth the trouble?
Logged
MichaelJPCT
float
Posts: 267
Re: shared shader but unshared uniform parameter?
«
Reply #1 on:
June 06, 2017, 06:50:56 am »
i found that it's not too much trouble.
Logged
EgonOlsen
Administrator
quad
Posts: 12297
Re: shared shader but unshared uniform parameter?
«
Reply #2 on:
June 06, 2017, 07:42:29 am »
You can use an
http://www.jpct.net/jpct-ae/doc/com/threed/jpct/IRenderHook.html
implementation und override the setCurrentShader() method in that one.
Logged
Print
Pages: [
1
]
Go Up
« previous
next »
www.jpct.net
»
jPCT-AE - a 3d engine for Android
»
Support
»
shared shader but unshared uniform parameter?