# Check the video aspect ratio

The video aspect ratio

The video aspect ratio is the relation of the horizontal to vertical size of a video image. When you pre-record video from analog cameras, the aspect ratio of the resulting video files is not the same as that of the source camera. This results in a distorted background image. In such cases, a perfectly circular Morris water maze may look ellipse-like in EthoVision XT after you grabbed a background image from the video file.

When is the video aspect ratio not correct?

The problem of the aspect ratio does occur:

▪When you record video with a program other than EthoVision XT, like MediaRecorder, and from analog cameras.

▪When you recorded video with EthoVision XT and you use that video in a new experiment.

If you record video and do tracking within the same experiment, the video aspect ratio is always correct.

How do I know that the video aspect ratio is distorted?

▪If the shape of the test enclosure as displayed in the background deviates from the shape that you expect. For example, a circular water maze looks like an ellipse, or a square open field looks like a rectangle.

▪Place a sheet with a circle under the camera and grab this image as background image. In the Arena Settings, draw a three point circle. If the aspect ratio of the image is correct, this three point circle fits over the circle from the camera image.

See Adjust the video aspect ratio

Calculate the correct aspect ratio in a video image

1.After grabbing the background image, locate the bitmap file of your background Image in the folder Bitmap Files of your experiment folder:

C:\Users\Public\Public Documents\Noldus\EthoVision XT\Experiments\[experiment name].

2.Open the file in an image editing program (such as Paint.NET).

3.Draw a shape exactly around the arena. Note the dimensions of the shape you have just drawn.

If the ratio (for instance, width/height) of the dimensions of the drawn shape deviates from the ratio of the real-world dimensions of the arena, this means that the image is distorted.

example 1 You have a perfectly circular water maze with a diameter of 100 cm. When you open the Background Image of this water maze in an image editing program and draw an ellipse around the maze, the ratio of width/height is not exactly 1 but is 1.019. This means that you need to adjust the aspect ratio of the Background Image using this ratio: in the Adjust Aspect Ratio window, in the Custom field, divide the width (box on the left) of the image by 1.019. Do not change the height.

example 2 You have a square open field measuring 40 x 40 cm. When you open the Background Image of the open field in an image editing program and draw a rectangle around the open field, the ratio of width/height is not exactly 1, but is 0.8. This means that you need to adjust the aspect ratio of the Background Image using this ratio. In the Adjust Aspect Ratio window, in the Custom field, divide the width of the image (box on the right) by 0.8. Do not change the height.

See also

▪Adjust the video aspect ratio