VideoCAD

Modeling cameras with Fisheye lens

Hide Navigation Pane

Modeling cameras with Fisheye lens

Previous topic Next topic No directory for this topic Expand/collapse all hidden text  

Modeling cameras with Fisheye lens

Previous topic Next topic Topic directory requires JavaScript JavaScript is required for expanding text JavaScript is required for the print function Mail us feedback on this topic!  

The view area of Fisheye cameras is a part of sphere. Field of view is projected by a Fisheye lens in the form of circle.

Depending on the ratio of sizes of this circle and the active area of the image sensor, there are 3 types of FishEye lens:

 

See more Fisheye

See also about Fisheye lenses in Wikipedia

 

Problem

 

There is a camera BOSCH FLEXIDOME IP panoramic 6000. The camera is mounted on a bracket at 3m height at a distance of 10 meters from a wall of 10 meters height. Camera is pointed down.

It is required to obtain a model of the control area, the distribution of the pixel density and image models from this camera.

 

The camera has 2 versions:

 

 

NDS-6004-F360E

NDS-6004-F180E

 

Circular FishEye lens

FishEye lens of Cropped circle

 

Pixels:2640 x 2640

Pixels:3640 x 2160

 

View angles: 180° (H) x 180° (V)

View angles: 180° (H) x 93° (V)

 

Order of work

 

       1. Creating a camera

 

1.1 Create a camera by clicking the New camera button. In the New camera box, in the Camera icon combobox choose an icon for the new camera with panoramic, for example indoor/panoramic .

 

A special icon is not obligatory. In the future it will be possible to change the icon in the Camera list box.

 

       2. Setting camera parameters

 

If the camera model is present in the database of real camera models, then there is no need to enter the camera parameters manually, just select the model from the Active Camera Model list or in the Table of Camera Models. The manual input of parameters is described below, for a case this camera model is not available in the database of real models.

 

2.1 Open the Camera geometry box and specify number of pixels on horizontal and vertical - 2640*2640 (for version 360°) or 3640*2160 (for version 180°) .

 

The most important parameter that determines the image resolution of Fisheye cameras, is the number of pixels of the image sensor.

 

Since the image sensor is rectangular in shape and view area of the camera is projected into a circle, not all pixels are involved in image formation.

In VideoCAD the number of physical pixels on the sensor horizontally and vertically are required. The number of pixels involved in the formation of the image will be calculated by VideoCAD.

 

Lens focal length and Image size at image processing have no affect on the image resolution of Fisheye cameras.

 

2.2 Click on the button on the Toolbar open the PTZ or Fisheye panel..

 

 

Check the Fisheye switch.

 

On the Camera Position panel, select the camera installation angles. In order for the lens to be directed from top to bottom (mounting on the ceiling), click the button. As a result, the angles will be set:

Hor. angle = 0°;
Tilt angle = 90°.

 

Set Circular FOV angle of the Lens = 180°, according to the camera model specification.

 

The Mapping function is not specified in the camera specification, so we select the Equisolid angle by default.

 

For version 360°

 

For version 180°

 

By clicking on the button, set the circular shape of the view area, according to the specification of the camera model. As a result, the view angles limited by the image sensor will be set equal to the circular view angle of the lens (180°).

By clicking on the button, set the shape of the view area as Cropped circle, according to the specification of the camera model. VideoCAD will calculate the expected view angles limited by the image sensor (180° (H) x 98.3° (V)) and the circular lens view angle (180°).

 

If necessary, we can correct the real vertical view angle of the sensor from the camera specification - 93°.

 

We leave the DORI factor at default = 0.7. Below we will return to selection of this factor.

 

A schematic drawing on the panel will display the position of the camera.

 

Lens focal length comboboxes in the Graphics window and in the Camera Geometry box will be colored aqua.

 

 

       3. Placing the camera on the layout

 

3.1 Place the camera on the layout. At the distance of 10 meters from the camera create a wall of 10 m height using the Rectangle  tool. Near the wall place several 3D models.

 

3.2 In the Camera geometry box specify camera installation height of 3 meters.

 

To limit too big size of the view area projection use the Maximum distance of drawing view area box in the Camera geometry box

 

       4. Adjusting pixel density visualisation

 

4.1. Assign to the camera a Pixel density pattern to visualize the pixel density.  For this purpose open the Pixel density box. Clear the Active camera checkbox, then choose the pattern "European Standard EN 62676-4 2015" in the Pattern list. Then click Assign to assign the chosen pattern to the active camera.

 

Pattern criterion of pixel density for Fisheye cameras must be based on the pixel density (Pixel per meter (Pixel per foot), Pixel for object), but not on the field of view size. Criterion Field-of-view height, % of Field-of-view for object are not suitable to Fisheye cameras, because of Fisheye cameras have not a rectangular field of view.

 

4.2. Enable and adjust the pixel density visualization in the Graphics window.

In the popup menu of the Shadow button on the Toolbar of the Graphics window choose Within projection.

In the popup menu of the Fill projection button choose Filling

In the popup menu of the Pixel density button choose Discrete color.

 

As a result we will see in the Graphics windows the pixel density distribution of the camera on the height specified in the Pixel density pattern assigned to the camera.

 

For version 360°

For version 180°

 

The maximum drawing distance of view area projections is determined by the Maximum distance of drawing view area.

 

 

       5. Selecting the DORI Factor from DORI Values

 

 

There are DORI (Detection,Observation,Recognition,Identification) values in the specification.

 

 

In order for the pixel density distribution in VideoCAD to be exactly the same as in the camera specification, it is necessary to select the DORI factor to the maximum match of distances in the DORI table and in the Pixel density box. To calculate the DORI factor clock on the Calculate button and enter DORI distances.

 

 

For the NDS-6004-F360E model, the optimal DORI factor value = 0.53.

 

       6. FishEye camera in the 3D World window

 

6.1 Open the 3D World window. In the window we can see the distribution of pixel density in the form of coverage on the surrounding objects.

Using the navigation in the 3D space, we can see pixel density at any point on the surfaces around the camera, as well as we can detect invisible areas shaded by other objects.

 

For version 360°

 

For version 180°

 

 

6.2 Close the 3D World window.

 

 

       7.  FishEye camera in the 3D Video window

 

7.1 Open the 3D Video window.

 

Right-click on the 3D Video window to display the Image parameter panel and switch to the Panoramic tab.

 

Choose the switches: Positions> Show> Camera and Fisheye> Show> Full image

 

The 3D Video window will display the full image.

 

For version 360°

 

For version 180°

 

 

7.2 If you move the mouse cursor over the 3D Video window with the left mouse button pressed, the camera will change direction following the cursor.

Moving the cursor while pressing Shift will cause the camera to rotate around its axis.

 

 

7.3 Enable the Image Processing if it is disabled.

If PiP mode is enabled, you can select areas for viewing in real resolution by clicking on the image by the middle mouse button (wheel).

 

 

       8. Getting an image in real resolution

 

8.1 Mark Image> Real frame size in the Main menu of the 3D Video window.

 

8.2 Save the image to a file with the real 5MP resolution by selecting Image> Save As in the Main Menu of the 3D Video.

 

Saving in high resolution takes time, wait until the end of the process.

 

 

 

8.3 Clear Image> Real frame size in the Main menu of the 3D Video window.

 

       9. Obtaining dewarped frame fragments in real resolution

 

9.1 Mark the switch Fisheye>Show>Dewarped image fragment (on the Image parameter panel). By directing the camera on points of interest on the scene, we can see with what resolution these regions will be displayed by our camera.

 

9.2 Place 3D model of a man on the far border of green region, that is, where the pixel density is 25 pixels / meter. And direct the camera on the 3D model.

Let's try to change the lens focal length and make sure that only the size of the field of view is changed. Resolution of the image will remain constant.

 

 

 

9.3 Pan, tilt and rotation of the camera around its own axis, made in the usual way does not affect the position of the Fisheye camera. By rotation the camera in the usual way, you can view images from the Fisheye camera in different directions in the 3D Video. In this case, the view area will be limited by the Circular angle of the lens. Beyond this limit the image is cut.

 

You can change the Lens focal length, thereby changing the field of view size, but the image resolution in the 3D Video will always be maintained equal to the calculated resolution of the  Fisheye camera.

If the calculated resolution is worse, the resolution of the 3D Video will be artificially reduced. If the calculated resolution is better, then the PiP mode will be launched in the 3D Video.

The Image line in the Titles displays a virtual number of pixels for correct simulation of the resolution.

 

Distortion of a Fisheye camera images in the 3D Video is not modeled.

The simulated resolution is exact only at the center of the frame. Towards the edges of the frame the actual resolution is worse than simulated. The smaller the view angle, the more accuracy of simulating resolution on the edges of the frame.

For a more realistic model of the image, turn on modeling of compression and smoothing, or set the actual resolution of the lens (for accurate simulation the lens resolution you also need to specify the correct size of the image sensor).

 

       10. Modeling multiple Fragments using Positions

 

10.1 Open the Positions of active camera window by button on the Toolbar.

Click , rotate the camera on the layout and click again.  The camera positions at the moment of clicks will be saved as Positions.

 

 

10.2 Now go back to the 3D Video window, right-click on the window, open the Image parameter panel, switch to the Panoramic tab, and select the Positions> Show> Cam+positions (show camera and positions). Switch Fisheye> Show> Dewarped image fragment should be marked.

 

You will see the camera positions you set in the screen division mode. In each cell, the image resolution is limited by its own calculated value.

 

 

       11. Other FishEye camera simulation options

 

With the model of Fisheye camera VideoCAD can simulate real camera resolution with PiP, saving image with real camera resolution, motion blur, animated images and modeling camera sensitivity.

 

 

See also: Fisheye cameras