![]() |
How to make a mirror in the editor?? - Printable Version +- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum) +-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html) +--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html) +---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html) +---- Thread: How to make a mirror in the editor?? (/thread-21410.html) |
RE: How to make a mirror in the editor?? - Traggey - 05-09-2013 (05-09-2013, 10:28 AM)martinnord Wrote:(05-09-2013, 09:56 AM)palistov Wrote: Even if you could see the player (most games neglect to have player models visible in first person beyond their arms), mirrors are very impractical in games. The cost of redrawing or computing what part of a scene is visible in a mirror would make frametimes so high they would get arrested for drug abuse. To emulate one you'd have to carefully build the environment around the "mirror" and get a custom-made player model. Probably way more work than it's worth.What about taking a screenshot of the environment and using it as a texture for reflection, and only letting the mirror mirror the player and other moving objects? (in case you havent realised we are now in the part of discussion where its no longer in amnesia) Mirrors in game engines are done with cubemaps, cubemaps don't work that way. Either you mirror the entire thing, or you don't. A low-res real time cubemap isn't too expensive, but you really don't want to use it in an area where ''action'' will go down. And when I say low res, I mean 64 x 64, anything above that will have quite the impact. RE: How to make a mirror in the editor?? - Tiger - 05-10-2013 Have different models that show stages of change. One where you look like normal, one that shows you as a monster and all the stages between that. Place all those models in the same place, where you want them and make all of them inactive except the one where you are normal. Then you can make them change with triggers or timers. Like the others said, you could take a screenshot of the surroundings so that the "mirror" shows what's behind you. RE: How to make a mirror in the editor?? - Traggey - 05-10-2013 (05-09-2013, 10:18 PM)Robosprog Wrote:(05-09-2013, 01:13 PM)Traggey Wrote:(05-09-2013, 10:28 AM)martinnord Wrote:(05-09-2013, 09:56 AM)palistov Wrote: Even if you could see the player (most games neglect to have player models visible in first person beyond their arms), mirrors are very impractical in games. The cost of redrawing or computing what part of a scene is visible in a mirror would make frametimes so high they would get arrested for drug abuse. To emulate one you'd have to carefully build the environment around the "mirror" and get a custom-made player model. Probably way more work than it's worth.What about taking a screenshot of the environment and using it as a texture for reflection, and only letting the mirror mirror the player and other moving objects? (in case you havent realised we are now in the part of discussion where its no longer in amnesia) Cubemap from the reflective water is most likely just a normal pre-baked cubemap, nothing to worry about. RE: How to make a mirror in the editor?? - Acies - 05-10-2013 Just made this: http://www.youtube.com/watch?v=f-UZ9mt9Izs It's a water material - no cubemap. Some weird things happen. Performance-wise it's not advisable, go for a cubemap if possible. It's "real time" reflection though! RE: How to make a mirror in the editor?? - Your Computer - 05-10-2013 It should be noted that World Reflection must be turned on in the graphics settings for Amnesia for water materials to reflect the environment. RE: How to make a mirror in the editor?? - FlawlessHappiness - 05-10-2013 (05-10-2013, 07:19 PM)Acies Wrote: Just made this: That's brilliant! I'm guessing there are certain stuff that does not exactly work in the mirror. Just like particle-effects that doesn't know it's on the surface of the water, and therefore shows itself as if it was underneath it. Did you look at the objects that moved weird? RE: How to make a mirror in the editor?? - Your Computer - 05-10-2013 (05-10-2013, 11:25 PM)BeeKayK Wrote: Just like particle-effects that doesn't know it's on the surface of the water, and therefore shows itself as if it was underneath it. Particle effects are reflected by the water material reflection. That just shows how much more it can impact performance. RE: How to make a mirror in the editor?? - FlawlessHappiness - 05-10-2013 Yes, they are reflected. I've just experienced that even though i've placed them above the surface, it looks like they are underneath it. Which only happens because of the water-material RE: How to make a mirror in the editor?? - Acies - 05-11-2013 Weird things: 1. Odd pure white box at 00:18-->00:23. (It's possibly a fog area "bleeding through" the walls + mirror). 2. At 00:25 --> 00:37. I seem to be looking into a cubemap at the other side of the room (@ the glass window). RE: How to make a mirror in the editor?? - FlawlessHappiness - 05-11-2013 So, those two things should not be in range of the mirror, for it to display properly |