UPBGE / upbge

UPBGE, the best integrated game engine in Blender
https://upbge.org
Other
1.42k stars 180 forks source link

Request: Skybox + cubemap + Environment mapping #16

Closed Akira1San closed 8 years ago

Akira1San commented 8 years ago

Add support for Skybox + cubemap + Environment mapping. This feature should give the user game developer the ability to add reflection and refraction using a single global texture. Example link -> http://learnopengl.com/#!Advanced-OpenGL/Cubemaps

lordloki commented 8 years ago

Related: https://developer.blender.org/D1461 https://developer.blender.org/D1414

youle31 commented 8 years ago

Thanks. For skybox, it seems feasible (maybe we'll ask HG1 if he wants to integrate his patch into the upbge...) But for cubemap reflections, as say Moguri, it's an enormous technical challenge to integrate this into the "main shader" code. We have nevertheless added a GLSL template for cubemap reflections in the upbge (for 1 light source and 1 cubemap texture)

BluePrintRandom commented 8 years ago

Light probes eventually would be pretty neat,

Hg1's realtime cube mapped reflections shader is pretty sweet,

https://www.youtube.com/watch?v=OloKmKAlleM

that said, it's not easy to just duplicate and use it again,

(like to use the player cube map and math to fake cube maps on everything around you)

On Wed, Jan 13, 2016 at 8:57 AM, youle31 notifications@github.com wrote:

Thanks. For skybox, it seems feasible (maybe we'll ask HG1 if he wants to integrate his patch into the upbge...) But for cubemap reflections, as say Moguri, it's an enormous technical challenge to integrate this into the "main shader" code. We have nevertheless added a GLSL template for cubemap reflections in the upbge (for 1 light source and 1 cubemap texture)

— Reply to this email directly or view it on GitHub https://github.com/UPBGE/blender/issues/16#issuecomment-171363124.

Akira1San commented 8 years ago

I see.

youle31 commented 8 years ago

Finally it was feasible https://youtu.be/jbFFyU28Py8 :)

Thanks very much Lordloki for the links!

Akira1San commented 8 years ago

Looks cool!

panzergame commented 8 years ago

Sky/background render are now implemented : https://github.com/UPBGE/blender/commit/b89ff69de8db9ef76c8d07c526046770597b5422.