Thank you for the detailed explanation of the process. I watched some other tutorials but they didnt explain each step, so it felt like too much black magic. This helped me know what the nodes are actually doing
Thank you! There are awesome usecases of it. Low poly cars, buildings etc. And the awesome part is its just a quad! Which means entire 3d look gets rendered really really fast!🙂
"when you look at a window from a very fine angle, reflection increases a lot" Yeah, that's the Fresnel effect, which you already added in. Potentially tweaking the power value would have given you the desired effect without adding in a dozen more nodes? There's also a bunch of inverting coordinates that might be able to be factored out? Other than that, really neat technique. I wonder how difficult it would be to add pseudo lighting from outside into the rooms...
Hi Tobias, that might be true😅 Answer to your second statement is, yes it is doable to add a pseudo lighting. Interior mapping uses raymarching to March a cube. So it is very well possible to apply a phong lighting with a few more nodes.
If you want to get really anally retentive about it, you should call it total internal reflection (TIR). They just happened to call the specific shader effect 'Fresnell' in computer graphics, though Fresnell studied TIR and advanced our understanding of it greatly, he didn't discover it or coin the term. And ideally you want to base this effect on the index of refraction of the material for the most realistic result. Which should be 1.5 for glass, in the Fresnell node, not 0.7 as was put in the video, that's why there was not enough reflection, as the smaller that number is, the closer sideways you have to look at the surface to get TIR.
@@PeppoMusic it's called Fresnel because it's computing the Fresnel coefficient, using equations that Fresnel derived. He wasn't the first to realise that the amount of reflection vs refraction is dependent on the angle of incidence, but I believe he was the first to come up with equations for it. It would actually be less accurate to call it TIR, as that's a special case where all of the light is being reflected, whereas the node is also computing angles and indices where only part of the light is reflected and the rest is refracted. In those cases, the reflection isn't "total" (and as we're working with surfaces rather than solid volumes, "internal" is a potentially misleading term). How's that for anally retentive ;)
Hi, thank you so much for your video tutorial; it really inspired me. However, I have a small question: why do I need to use 1 divided by the product of view and -1?
Thanks for the video, I managed to re-create it in a different shader editor called Amplify Shader editor. Only one thing I've noticed, do you know why around the intersections of the walls, the interior is distorted? And is there a fix?
Does it improve performance? Or would it be better to just render a non-parallax texture of a interior model then project it onto a cube. Asking for my massive open world game.
Consider the polygon count, a cube has 6 faces, as far as I can see this only needs 1 face, so for each window you have 5 more faces, so for example with 10 windows, you have 50 additional faces, that'll really raise the polygon count, which will impact performence.
@@medafan53 But a shader to simulate all these faces are more expensive than poly count. I've seen benchmarks and it's only worth it when you use it in hundreds or so.
the preview images in my nodes don't look like yours. It's seemingly random whether they are square, like yours or round/spherical. It has the effect that I end up with a circle where only the upper right corner has the cubemap applied and the other three quarters are black... any ideas?
Very nice tutorial! but I am getting a weird effect, if you resize the quad where the material is applied so that it becomes a long rectangle, the effect looks very distorted. It only seems to be working on squares, is this a limitation of the method or am I doing something wrong?
Fantastic video. Thank you for this! Does anyone know who to modify the shader to create a parallax effect with an additional texture? To basically make it look like there are objects inside the room that would have a parallax effect relative to the back wall.
Hello, I'm trying to use this method in Blender but it doesn't seem to work. Most of the shader nodes are the same but some have different names and that makes it harder to copy into Blender.
Do you generate the cubemaps with reflection probes or another way? I'm finding the effect looks right when the reflection probe is centered in a room, but not if it's off-center like at a doorway or window.
I followed your exact steps, and my side walls are working. Not the back one though. The wall that's supposed to be "the back" of the room doesn't look flat, but is infinitely extending into a single point it seems. Maybe not wuite infinately, but i justneed a way to flatten it out.
Could this be the best way for optimizing a 3D game based on file size and computing power. Or does it take more resources to render and more storage space?
Generally speaking, shaders are the fastest way to render things in a game, but it entirely depends on what you are doing with them. In this case it is not a concern. Storage space depends entirely on the image resolution and format.
Interior Mapping/Fake Interiors should be faster. Cyberpunk 2077, The last of us part 2, even hypercasual mobile games all of them use this method. So it is pretty cheap and pretty fast. Unless you have too high resolution cubemaps, you should be fine.
It's even simpler to make a fake exterior. you can just sample the cubemap or a hdri directly with your view angle. the extra math in this is specifically to line the edges up with the window and to make a cube projection within the window, outside doesn't need to be a cube though
I love this! Really great job! One thing Im looking to achieve in my shader is instead of a cubemap use a texture, how I can modify it to make in works ? I tried but the walls, floor and ceiling looks super strech like 1 pixel of the texture. Thanks
@@MertKirimgeriGameDev I have a tile texture of 2x4 containing 8 different interiors. So each interior is square like a perspective projection having the top, down, sides and front of the room. Another thing I wanna do is those 8 interiors by random.
I see. It is possible with shadergraph but requires a bit of work in "virtual room size generation nodes" that I mentioned in the video. I can give you some resources that you can use for research. I'll probably hit another message here as a follow-up later today.
Absolutely! I tested it with HDRP too! Same nodes, same workflow. Nothing else needed! Since this technique is technically so naive, it should work with even a potato😜