Ambiera ForumDiscussions, Help and Support. |
|
[ 1 2 ] Page 1 of 2 |
|
|||||
|
A vertical surface that actually reflects what is in front of it (such as my character), in real time. |
||||
|
In the new version, you can achieve this with render to texture methods. Simply place a camera in the correct position and set the field of view (FOV) for rendering the image onto your mirror mesh. |
||||
|
SamGrady wrote: In the new version, you can achieve this with render to texture methods. Simply place a camera in the correct position and set the field of view (FOV) for rendering the image onto your mirror mesh. The new version of... CopperCube? You mean 6.7? Or are you referring to CopperCube 6.6 as the new version? And can you provide/show an example of doing this? |
||||
|
I'm referring to version 6.6. I can demonstrate some results shortly. It only takes 10 minutes to achieve this. |
||||
|
It looks like this: |
||||
|
@samGrady Can you send source(.ccb) to me please? |
||||
|
Of course, please take a couple of minutes to write an extension for improved usability. |
||||
|
Don't make it more complicated as it is. Make a texture and show it. Or did you want to make a real mirror for a car game or Fighter Jet Simulation? |
||||
|
Here it is, this action doesn't perform optimally (as ccbRenderToTexture at all), but you can still use it. Please keep in mind that adding more mirrors may result in reduced performance. https://samgrady.itch.io/copperc... |
||||
|
Inside the demo, I demonstrate how to use this action and create two planes to showcase a particular issue you might encounter, which is the flipped polygons with the default plainMesh. Within the action, you'll find four parameters: 1."MirrorSurface" - the mesh node for the mirror, where the reflection from the camera is rendered. 2."Camera" - the camera node used to capture the view rendered onto the mesh. 3."ReflectionQuality" - controls the resolution of the image rendered on the mesh. 4."MaterialIndex" - specifies the index of the material for rendering on the mesh. I hope you find this action useful and enjoy using it! |
||||
|
I am considering creating the next version based on the 'On proximity do something' approach, which would draw reflections only when you are close enough to the mirror and stop doing so when you are not. But for now, feel free to use and experiment with this version. |
||||
|
Very cool extension, thanks Sam! Another possibility is to use the water mesh reflexion how mirror, just need adjust the parameters, you could try too! |
||||
|
SamGrady wrote: It looks like this: But doesn't that only show a static object view, like the cube in the mirror. If you controlled the cube, would it accurately reflect where (and/or how close) it was in relation to the mirror, just like a real mirror would? That's what I'm trying to achieve. Not just the "effect" of a mirror, but the actual properties of a mirror, accurately reflecting something being moved in front of it in real time. UPDATE: I downloaded your code example and what I'm trying to achieve may actually be happening. I'll experiment more after dinner. |
||||
|
Why are there two cameras (one of them named mirror_flip)? You don't NEED two planes and two cameras, do you? I only need one of them (1 mirror) for the end of Stage 3 in my game. |
||||
|
Why are there two cameras (one of them named mirror_flip)? On using the standard plane, the image is projected inverted from left to right. To correct this, you'll need a mesh flip. |
[ 1 2 ] Page 1 of 2 |
|