# Calculating a camera's Focal Length when given Field Of View (and vice versa)?

Are there any formulas that I can convert from FOV-to-FL and from FL-to-FOV?

I need to match a camera from the Unity game engine to Blender (and vice versa). Unity uses Field Of View and Blender uses Focal Length.

Is this achievable in an easy way?

[EDIT]

Just stumbled across this formula:

horizontal field of view = 2 atan(0.5 width / focallength)


I'm writing a python script now to test it. Hopeful this works.

[EDIT]

It would appear that Blender already has the ability to set a camera's FOV directly. Thus I can solve my issue directly and no longer need to convert anything.

• Did you last edit solve your problem? In this case you might add an own answer and accept it. – bummi May 11 at 12:27