Skip to Content

What is the size of the Lens in Lens Studio?

What is the size of the Lens in Lens Studio?

The Lens in Lens Studio refers to the virtual camera that is used to view and capture content created in Lens Studio. The Lens has a default size and field of view that can be customized based on the needs of the Lens experience being created.

Default Lens Size

The default size of the Lens in Lens Studio is designed to approximate the field of view of a smartphone camera. The exact field of view varies slightly between different smartphone cameras, but is generally in the range of 60-70 degrees.

In Lens Studio, the default field of view of the Lens is set to 65 degrees. At a 16:9 aspect ratio, common for smartphone screens, this equates to:

  • Horizontal field of view: 65 degrees
  • Vertical field of view: 36.6 degrees

This creates a natural perspective similar to taking photos or videos with a smartphone camera. It allows for a balance between having a wide enough field of view to capture a scene, while still maintaining a realistic perspective.

Customizing the Lens Size

While the default Lens size is optimized for mobile AR experiences, Lens Studio provides controls to customize the size and field of view of the Lens as needed.

There are two main ways to customize the Lens size:

  1. Adjusting the Field of View (FOV)
  2. Changing the Near and Far Clipping Planes

Adjusting Field of View

The field of view of the Lens can be directly adjusted using the “Field of View” property in the Camera component. This is specified in degrees, with higher values creating a wider field of view.

For example, setting field of view to:

  • 90 degrees creates an ultrawide, fisheye-like perspective
  • 40 degrees creates a narrow, telephoto-like perspective
  • 65 degrees (default) creates a natural mobile perspective

Adjusting field of view is useful for creating specialized camera effects or emphasizing different parts of a scene.

Changing Near and Far Clipping Planes

The near and far clipping planes define the closest and furthest distances the Lens can see. Objects closer than the near plane or farther than the far plane will not be visible.

The default clipping planes in Lens Studio are:

  • Near plane: 0.01 meters
  • Far plane: 1000 meters

Bringing the near plane closer crops out more of the scene in front of the camera. This can create a miniaturization effect or macro perspective.

Reducing the far plane creates a foggy or isolated look by limiting how far the Lens can see.

Increasing both clipping planes expands the visible range of the Lens, creating an open and expansive perspective.

The clipping planes can be adjusted on the Camera component:

This allows the perspective and visible range of the Lens to be fine-tuned as needed.

Orthographic Lens

In addition to the regular perspective Lens, Lens Studio also provides an orthographic Lens option. This creates an orthographic parallel projection rather than a perspective projection.

With an orthographic Lens, objects maintain their size regardless of distance from the camera. This is useful for creating 2D experiences, UI screens, and effects where consistent scaling is desired.

The orthographic Lens can be enabled on the Camera component:

When enabled, the Field of View and clipping plane properties are ignored. The orthographic size property controls the vertical size of the viewing window.

The orthographic Lens is fixed at a constant size and does not represent a real-world camera. But it provides unique creative opportunities for mixed reality experiences.

World Scale

In addition to the camera settings, the overall scale of the world in Lens Studio also impacts the feel of the Lens perspective.

The default world scale is:

  • 1 unit = 1 meter

This provides a 1:1 real-world scale where objects, distances, and physics behave realistically.

The world scale can be adjusted under Project Settings:

Larger world scales make the world feel small like a miniature model. Smaller scales make the world feel large and expansive.

Adjusting world scale lets you tune the overall look and feel of the Lens experience separate from the Lens camera itself.

Previewing the Lens View

When customizing the Lens in Lens Studio, it’s important to preview how it will look in the app. The Lens Simulator provides a mobile preview of your Lens:

Additionally, building and running your Lens on a device will show exactly how the Lens camera will look and feel.

Lens Size Best Practices

Here are some best practices when working with Lens size and perspective in Lens Studio:

  • Start with the default Lens FOV and clipping planes to match a mobile perspective.
  • Increase FOV for wide-angle effects or reducing for a zoomed-in look.
  • Adjust clipping planes to limit scene visibility or expand it.
  • Use orthographic Lens for UIs and 2D effects.
  • Tune world scale to tweak overall look and feel.
  • Always preview on device to see the real Lens perspective.

With the power to customize FOV, clipping planes, orthographic projection, and world scale – Lens Studio provides immense flexibility for the Lens camera. Use these tools to craft unique perspectives that enhance your Lens experience!

Conclusion

The default Lens in Lens Studio approximates a mobile phone camera perspective, with a 65 degree field of view. However, the FOV, clipping planes, orthographic projection, and world scale can all be customized to achieve different camera looks and feels. Previewing on device is key, as the Lens perspective ultimately depends on real-world size and distance. With practice, the creative possibilities of the Lens camera are endless!