How to dynamically position camera above centre of board game - Unity3d - unity3d

I am writing a mobile game that dynamically generates 3d items on a canvas.
However, I am struggling with 2 things:
Have the underlying plane scale to fit the size of the screen
Shift the camera so that it moves directly above the plane and looks down at the objects.
Therefore, changing the scene from something like this:
To something like this:
I have been going through the camera tutorials, but they mostly are for '3d games' and not for a camera that looks down from above, flattening the 3d space. I need to use 3d cubes because the game rotates them during play.
Would appreciate some tips on what material to look at!

Related

Clamp camera within bounds of a Polygon Collider?

Hi I am making a 2d platformer game and right now I am working on the camera. while I succeeded in clamping the camera inside a rectangular shape, my game involves slopes, so I want my camera to be able to clamp inside a curved shaped too. Can anyone help me find an idea for the code?
Cinemachine gives you a flexible 2D camera controller, with the option to confine it inside a PolygonCollider2D. This section contains explanation for that and other cool things.

How to get a circular view in unity

I am developing an application for Pico VR headset using Unity. The SDK has a prefab containing two camera.
I have added a quad and a script to change its texture at runtime.
Since the quad is rectangular and display is circular, my texture is unable to fill the screen. If quad is too close to camera, the corners cannot fit the display. If its so far that corners are able to fit inside the headset's display, I am able to see the background at the edges.
The display of HMD looks like a circle (may be spherical - because I have observed the texture that I apply on to the quad looks zoomed in when I run the app on the device). I want to add such object and configure my cameras so that they can view the entire texture of that object and nothing else.

How to make pseudo 3D or 2.5D effect?

After using Unity for over a year now for creating 3D games I'd like to do my first pseudo 3D or 2.5D game (or whatever it's called). What I mean is games like Clash of Clans or Boom Beach where objects are really 2D images rendered to give 3D feeling. Because I don't even know the correct word for that type of games it's really hard to get started. What I can think of is giving Camera rotation of (45, -45, 0) so that it looks down at the ground from the upper right corner and then creating empty gameObjects with Sprite Renderers and setting their rotation to (22.5, -45, 0) so that they face the camera. I don't know if that's how it's really done so could somebody give me a link to some neat tutorial or something because I'm stuck.
The keyword you are looking for is isometric projection.
You can use Unity to create that effect with 3D graphics. You need to set the camera rotation to (45, -45, 0) and set the Camera Projection to Orthographic.
If you want to only use 2D graphics then the graphics are made in such a way that they are drawn in an angle that it looks like you are looking at them in 45 degrees.
If you search for isometric unity then you should find a ton of tutorials for Unity.

Unity3D - Embedding a 3d scene in a 2d scene

I'm fairly new to Unity and I'm trying to embed a 3d view inside a 2d one.
I'm working on an emulation app that has a 2d UI for controls and a preview of the result in a 3d box that should be embedded in the 2d one, sort of as a player.
What's the right approach to doing that in Unity? Is there a way of "embedding" one scene in another?
Thanks!
If you want to create 3D effect with UI canvas, you should look to this link.
If you are using 2D project, it is basically 3D scene with camera set to use ortographic projection, not perspective. So you can use 3D models as well.
You should look into Render Texture. Those allows to render a camera view onto a texture in a scene. Say you have a part of a scene an dyou want to render onto a TV screen in your game. You would place the TV scene somewhere and place your camera to view it. Then you create a render texture and apply onto the mesh that is making your tv screen.
Now if you wish to make a UI system, like a radar with a top view, you would modify the viewport of your top view camera (0,0,.2,.2 would place it bottom left corner with 20% height and width) and make the depth higher so that it renders on top of the main camera.

Using PointCloud Prefab on Unity 3D

I tryed to implement the "Measure It" app on Unity 3D. I started with the PointCloud example scene downloaded on tango's website.
My problem is, when i look in 1st Person view, the point cloud don't fiel the screen, and when i look in 3rd Person I can see the point outside the Unity Camera FOV.
I don't see this problem on the Explorer app, but it looks to be made in Java so I think it's a Unity compatibility problem.
Does someone have the same problem, or a solution?
Unity 3D 5.1.1
Google Tango urquhart
Sorry for my poor english,
Regards.
EDIT :
It looks like the ExperimentalAugmentedReality scene is using the point cloud to place markers in real world, and this point cloud is right in front of the camera. I don't see any script difference between them so i don't understand why it works. If you've any idea.
I think it makes sense to divide you question into two parts.
Why the points are not filling in the screen in the point cloud example.
In order to make the points to fill in the first person view camera, the render camera's FOV needs to match the physical depth camera's FOV. In the point cloud example, I believe Tango is just using the default Unity camera's FOV, that's why you saw the points is not filling the screen(render camera).
In the third person camera view, the frustum is just a visual representation of the device movement. It doesn't indicate the FOV or any camera intrinsics of the device. For the visualization purpose, Tango explore might specifically matched the camera frustum size to the actual camera FOV, but that's not guaranteed to be 100% accurate.
Why the AR example works.
In the AR example, we must set the virtual render camera's FOV to match the physical camera's FOV, otherwise the AR view will be off. On the Tango hardware, the color camera and depth camera are the same camera sensor, so they shared a same FOV. That's why the AR example works.