Jump to content
IGNORED

Videogames & Mirrors


teddymeow
 Share

Recommended Posts

Why is it most games can't do mirrors properly? As in, when you're playing and you stand in front of a mirror there's either no reflection or just an out of focus blob that's supposed to represent your character.

 

I've just finished Uncharted 4 again and the mirrors in that give proper reflections of your surroundings.

 

Gears 5, on the other hand, the mirror doesn't.

 

It is purely a console horsepower thing?

 

What other games do mirrors well? I seem to remember Prey (the newest one) had reflections.

Link to comment
Share on other sites

I’ve heard people on YT mention that mirrors are always intriguing if you have a background in testing because they never really work - people say that as soon as you’re able to get another reflective object in front of the mirror it’ll probably crash. So I guess it’s something to do with representing objects in the world on that reflective surface, and things get more demanding if there are multiple reflective surfaces.


(EDIT: I think I heard the claim on a video about Luigi’s Mansion, which has “working” mirrors)

 

This is all stuff I’ve heard though; I don’t necessarily know how accurate the claims are. Wouldn’t the visual effect of a mirror be similar to the visual effect of Portal’s portals?

Link to comment
Share on other sites

Silent Hill 2 had a working mirror at the very beginning IIRC. I was really impressed at the time.... think it was the third game I played on the PS2!

 

Conversely first game I played on the PS4 was Killzone : Shadow Fall. Whilst messing about on the first level decided to check out the power of the PS4 and see my reflection in a vending machine. It wasn't there... :(

Link to comment
Share on other sites

I was always under the impression that there’s no such thing as a ‘working’ mirror in games, it’s always been some form of trickery, because a ‘real’ mirror would require ray-tracing which until very recently couldn’t be done in real-time. Same

with all other forms of reflection; puddles, glass, metal etc. 
 

Next-gen feature confirmed?

Link to comment
Share on other sites

As far as I know, in the past real mirrors were usually so rare because essentially it meant processing the scene twice, once for the 'real world' and once for the reflection. However I'm sure these days there are far more clever methods, I can remember quite a few games lately which did (seemingly) true mirrors - or it could just be that horsepower and optimisation means you can brute force mirrors from a technical perspective now. 

Link to comment
Share on other sites

11 minutes ago, CarloOos said:

I was always under the impression that there’s no such thing as a ‘working’ mirror in games, it’s always been some form of trickery, because a ‘real’ mirror would require ray-tracing which until very recently couldn’t be done in real-time. Same

with all other forms of reflection; puddles, glass, metal etc. 
 

Next-gen feature confirmed?

Yup. Screen Space Reflections, which can only 'reflect' what is being rendered on screen, unlike Ray Tracing.

 

 

 

Link to comment
Share on other sites

Given that the new consoles support ray-tracing it's possible we might start having the opposite problem, with mirrors and reflections everywhere for no good reason.

 

In terms of 'real' mirrors, I think more recent games will have mainly used render to texture. Essentially this involves rendering another camera view of the game world – typically at a lower resolution – then mapping that to a texture that updates in real time; the same technique might be used for a working CCTV monitor, or things of that nature. Hitman 2 (2018) would be a recent example of this technique being used quite a bit.

Link to comment
Share on other sites

33 minutes ago, Alan Stock said:

As far as I know, in the past real mirrors were usually so rare because essentially it meant processing the scene twice, once for the 'real world' and once for the reflection. However I'm sure these days there are far more clever methods, I can remember quite a few games lately which did (seemingly) true mirrors - or it could just be that horsepower and optimisation means you can brute force mirrors from a technical perspective now. 

 

This was pretty much what I was going to say. I saw something on a YT video not too long back that mentioned mirrors and explained that it needed to incorporate twice the amount of processing of a scene in order to look realistic. 

Link to comment
Share on other sites

Hitman 2 shows that fakey methods aren't beyond the reach of current gen console horsepower.

 

Most games don't have mirrors because 1. they look stupid in first person games and 2. they draw attention to the fact that there aren't proper reflections anywhere else.

Link to comment
Share on other sites

For the most part it's a technical issue, but not because the hardware isn't powerful enough to actually do it. Most engines, or at least the games built in those engines, are optimised to only render what the main camera is showing, which means if you put a mirror in a scene there's actually nothing to reflect because it's simply not being rendered by design. 

If you play a game with working mirrors, the trick is usually done by rendering the entire scene twice and put the mirrored version on the face of the asset that's supposed to represent a mirror. 

Ironically, Duke Nukem 3D had working mirrors without any performance penalties, but that's more down to it not being an actual 3D game, but rather 2D textures being placed in a faux 3D environment. 

Modern games featuring mirrors, like Prey, only featured them in small and confined spaces, like the mirror in the intro scene which was basically a small bathroom. 

Link to comment
Share on other sites

5 hours ago, Dimahoo said:

Well...theres been one or two driving games.

 

I hadn't actually thought of that when I started the thread.

 

Is it because those mirrors are tiny so they use less processing power? 

 

I hope it doesn't become a tickbox next gen. A bullet point on the box.

Link to comment
Share on other sites

Just now, grindmouse said:

Fully ray-tracing mirrors are going to be the biggest jump in gaming since 3D. @PC Master Race ;)

Yes. Games dumping pre baked and fake lighting for ray tracing will be the biggest change since the jump from 2D to 3D. Now stop interrupting the grown ups and toddle off back to your ludicrous FFVII thread.

Link to comment
Share on other sites

3 hours ago, teddymeow said:

 

I hadn't actually thought of that when I started the thread.

 

Is it because those mirrors are tiny so they use less processing power? 

 

I hope it doesn't become a tickbox next gen. A bullet point on the box.

 

I'm not sure. In real world screen estate the size of them maybe quite similar - depending on the game however in the past mirrors were always rendered poorly with a lack of detail.

Link to comment
Share on other sites

3 hours ago, teddymeow said:

I hadn't actually thought of that when I started the thread.

 

Is it because those mirrors are tiny so they use less processing power? 

 

Mirrors in driving games would be considered part of the core game, rather than just a nice bit of detail, so resources would be allocated to ensure they work to a reasonable standard. Much like you wouldn't expect the physics of a game like Gran Turismo to be present in Far Cry - different priorities.

 

Even so, a rear view mirror is still just a rear-facing camera rendered to a texture, usually with a lower resolution, level of detail and draw distance. Enough so you can use it for its purpose, but not perfect by any means.

Link to comment
Share on other sites

3 hours ago, teddymeow said:

I hope it doesn't become a tickbox next gen. A bullet point on the box.

 

It will be the new lens flare for upcoming generation. So it will be 4K@30fps lots of mirrors and light effects.... got to find some graphics effects to squander all that processing power on :D

Link to comment
Share on other sites

10 hours ago, Fry Crayola said:

 

Yes.. and also no.

 

Yes in that there was a mirror on the wall and you could see James in it. But no, because it wasn't actually a mirror as far as the engine was concerned - it was a hole in the wall behind which lay an exact mirrored copy of the bathroom and another James that you also controlled.

 

Reminds me of this incredible hidden camera show gag

 

 

 

Link to comment
Share on other sites

In the old days (the first few generations of 3D - things may be different now) they would have been a massive pain in the arse, from a 3D rendering point of view.

 

You'd essentially be having to do all the 3D transformations for everything in the scene twice, once for the camera, and once again for the view inside the mirror, which is would have been be a fair performance hit for something non-essential, often just an inconsequential cosmetic prop added quite late as a whim by an environmental artist, after the engine parameters and performance had probably already been locked down.  Hence the trick of making mirrors smashed (Fallout games), or too dirty to reflect properly.

 

It was always perfectly doable if you needed to - if it was part of an important game mechanic, or you built your game around an idea like this (a rear view mirror in a driving game, Portal, etc.), but generally it's a feature that would need to be specifically programmed, with a significant performance overhead, so would typically only be implemented if it needed to be.


There were fun ways of faking it.  The mirror that is actually a just a hole in a wall, with a flipped model of the room on the other side, and duplicate versions of any moving characters in the room on the other side with their movement matching & mirroring the movements in the real room.  A few games did things like this, but you wouldn't want to do this in, say, every Fallout room with a mirror in it.


That said, it wouldn't surprise me if modern engines could just include mirrors as a default, out-of-the-box pre-implemented feature, and they start to become common place in games even when they're purely cosmetic.

Link to comment
Share on other sites

11 hours ago, Fry Crayola said:

 

Yes.. and also no.

 

Yes in that there was a mirror on the wall and you could see James in it. But no, because it wasn't actually a mirror as far as the engine was concerned - it was a hole in the wall behind which lay an exact mirrored copy of the bathroom and another James that you also controlled.

 

Metal Gear Solid on PS1 did something like that too, but didn't duplicate Snake's model:

 

 

Link to comment
Share on other sites

In MGS2, you can see Snake's reflection on mirrors in firstperson view, but - in hindsight - I don't think there's a way to get him visible in a mirror in the thirdperson camera because you can't get close enough to the mirrors with the sinks in the way in top-down view, and there's never a convenient corner peek view. In hindsight, when you go in to firstperson view they probably just switch from drawing Snake in the game world to drawing him on the other side of the mirror.

 

All of this reminds me of how much of a modern game's rendering is currently done in "screen space", i.e. the engine basically only knows the properties of each pixel (which bit of which polygon it lies on) and how far that is from the camera, and not the whole geometry of the scene.

 

http://www.adriancourreges.com/blog/2015/03/10/deus-ex-human-revolution-graphics-study/

 

 

 

Link to comment
Share on other sites

58 minutes ago, Fry Crayola said:

Even so, a rear view mirror is still just a rear-facing camera rendered to a texture, usually with a lower resolution, level of detail and draw distance. Enough so you can use it for its purpose, but not perfect by any means.


After I made my previous post I thought “but on the other hand surely it’s “just” a view from a virtual camera?” And “views from cameras on screens” was one of the tech demos when Valve were showing off HL2’s iteration of the Source engine if I recall. So it could probably be faked in some instances, but the more complex and “authentic” techniques will be more demanding... :) 

Link to comment
Share on other sites

A mirror is not a mirror. The mirror is the environment flipped which means the entire scene has to be calculated/rendered twice. Case in point, the very beginning of Silent Hill 2.

 

 

Link to comment
Share on other sites

13 hours ago, Darhkwing said:

Mario 64 had a great mirror. I'm sure there was some crazy trickery involved.

 

Here's a video of a player showing what's behind there (from about 0:56). The duplicate copy of the Snowman's Land painting doesn't work as a warp into the level!

 

 

Link to comment
Share on other sites

I seem to recall a few years ago people talking about a "trick" in Project Gotham Racing for doing the reflections of the gameworld onto the bodywork of the cars. What was that trick? Also, how did Codemasters do the reflections on cars in the Dirt series, as they reflected the world and also the other cars, and I thought it looked really impressive. 

Link to comment
Share on other sites

7 hours ago, Rayn said:

Ironically, Duke Nukem 3D had working mirrors without any performance penalties, but that's more down to it not being an actual 3D game, but rather 2D textures being placed in a faux 3D environment. 

 

4 hours ago, StoooTube said:

I think Duke Nukem was the first game I played with working mirrors...

 

They hacked it in quite an interesting way by drawing a flipped space through the 'portal' of the mirror, and then putting an invisible wall there so you couldn't enter it

 

 

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Use of this website is subject to our Privacy Policy, Terms of Use, and Guidelines.