2026-10-19

A 4 mm lens is 68 degrees until the datasheet says 90

Hikvision DS-2CD1023G0E-IDS-2CD2T23G0-I5AICO ACM127F02820IRMM1/2.7 inchM12CS mountfocal lengthfield of viewbarrel distortionDORIIEC 62676-4pixel density
A 4 mm lens is 68 degrees until the datasheet says 90

One camera, two field-of-view numbers

A selection guide published on 19 October works through a single example. A 2 MP camera, a 1/2.7-inch sensor, a 4 mm lens. The sensor is 5.4 mm wide, so the horizontal field of view is twice the arctangent of 5.4 divided by 8, which is 68 degrees. At ten metres the frame is 13.5 m wide. Divide 1,920 pixels by 13.5 m and you get 142 pixels on every metre. The verdict: at ten metres the camera sees a person but cannot identify a face.

Every step of that arithmetic is correct. The formula is the standard pinhole relation, the sensor width is the commonly quoted figure for that format, and the division is right.

Now read the specification sheet of a camera that matches the description exactly. The Hikvision DS-2CD1023G0E-I is a 1/2.7-inch progressive scan CMOS sensor, 1920 x 1080, F2.0, M12 mount, offered in 2.8 mm and 4 mm versions. For the 4 mm version the sheet prints three numbers: horizontal field of view 90.2 degrees, vertical 48.6 degrees, diagonal 107.6 degrees.

Ninety degrees is not a rounding difference. At ten metres a 90.2-degree frame is 20.07 m wide, and 1,920 pixels spread over 20.07 m is 95.7 pixels per metre. Same camera, same focal length, same distance. One method says 142, the other says 95.7. The gap is 33 percent, and it is enough to move the camera across a whole tier of what it can actually resolve.

Neither number is a mistake. They answer different questions, and the difference is the subject of this article.

Two cones from one lens: 68 degrees by the geometry, 86 by the datasheet

What the focal length actually sets

The pinhole relation is worth stating precisely because everything downstream depends on the version you use. For a sensor of width w and a lens of focal length f, the horizontal field of view is 2 arctan(w / 2f). The scene width at distance d is 2 d tan(half the angle), which collapses to d times w over f when the angle is small. That last simplification is where a lot of field estimates quietly go wrong, because at 68 degrees the tangent is already 0.67 rather than 0.40, and the "small angle" shortcut is off by two thirds.

The model assumes light travels in straight lines, the image plane is flat, and the lens maps angle to position linearly. On a machine vision lens with a 5 megapixel sensor and a narrow angle, all three hold closely enough that the formula lands within a degree.

On a security lens that has to cover a whole room from two metres away, the third assumption fails first. A wide lens bends straight lines outward at the edges, and the bend is not small.

The focal length survives all of this untouched. A 4 mm lens is still 4 mm. What changes is how much of the real world that 4 mm has to fold onto a 5.37 mm wide strip of silicon.

That folding is not free, and the lens datasheets say so in a field that the camera brochures usually drop.

Where the extra degrees come from

A lens catalogue lists a 2.8 mm M12 lens for exactly this sensor format. Its specification line reads: focal length 2.8 mm, sensor 1/2.7 inch 5.37 x 4.04 mm, image circle 6.72 mm, field of view 145 degrees diagonal, 111 horizontal, 82 vertical, optical distortion better than minus 63.4 percent.

Stop at the last number. The same sheet that says the lens covers 111 degrees horizontally also says it distorts the image by 63.4 percent. Those two statements are the same statement.

Run the pinhole formula on a 5.37 mm wide sensor with a 2.8 mm lens and you get 87.6 degrees. The datasheet says 111. The missing 23.4 degrees are the distortion. The lens is not collecting more light from a wider angle in some free way; it is compressing a wider angle into the same strip of pixels, and the compression is strongest at the corners.

The manufacturer's other two lenses for the same format show the pattern collapsing as the focal length grows:

Focal length Datasheet HFOV Pinhole HFOV Extra degrees Distortion
2.8 mm 111 87.6 23.4 63.4 percent
6 mm 60 48.2 11.8 20 percent
8 mm 44 37.1 6.9 10 percent

The three lenses are not a matched family, and the sign convention on the distortion figure is not even consistent across the three pages, so read the column as magnitude rather than as a signed coefficient. What it shows survives that caveat: the extra field of view tracks the distortion almost one for one. At 2.8 mm a fifth of the quoted angle is barrel; at 8 mm it is a sixth.

The 6 mm and 8 mm rows also settle a question the first row raises. If distortion were an error in the datasheet rather than a property of the lens, the extra degrees would not shrink so neatly with focal length. They do shrink, in the order you would predict from a lens design that bends less as it gets longer.

Pinhole angle against datasheet angle for three focal lengths, with the distortion each carries

What the camera datasheet is actually reporting

The three lenses above are not the ones soldered into any particular camera. They are the same format, the same mount family, and the same manufacturer's catalogue of what a 2.8, 6 or 8 mm lens does to a 1/2.7-inch sensor. That is enough to explain where the camera numbers come from.

Line up two independent sources for the 2.8 mm case. The lens maker quotes 111 degrees horizontal. Hikvision's 1/2.7-inch 2 MP model quotes 112.1 degrees. Hikvision's 1/2.8-inch model quotes 114 degrees. Three sources, three sensors, one angle to within three degrees.

Now the 8 mm case. The lens maker quotes 44 degrees. The Hikvision 1/2.8-inch model quotes 43. Two numbers a degree apart, from a lens catalogue and a camera brochure.

The pattern holds across the range, and it tells you what the camera sheet is printing. It is printing the lens's full distorted field of view, not the geometric angle that the sensor width and focal length would produce. When a specification sheet says a 4 mm lens gives 86 degrees, it is reporting the widest angle that still lands light on the sensor, corners included.

That is not a dishonest number. It is the angle you actually see. But it is a different quantity from the one the selection formula computes, and the two are not interchangeable.

The reverse calculation makes the size of the discrepancy concrete. Take the 90.2 degrees that the 1/2.7-inch 4 mm model quotes and solve for the effective sensor width: 2 times 4 mm times tan(45.1 degrees) is 8.03 mm. The sensor is 5.37 mm wide. The quoted angle behaves as though the sensor were fifty percent wider than it is.

For the 1/2.8-inch model at 86 degrees, the same inversion gives 7.46 mm. Two cameras, two sensors, one shared conclusion: the number on the box is not the number the formula produces.

What a wider angle does to a pixel per metre

Pixel density is horizontal resolution divided by scene width, and scene width is the only place the field of view enters. So a fifty percent error in the angle becomes a fifty percent error in the density, which is the quantity every coverage decision actually depends on.

Running both methods at ten metres, with 1,920 horizontal pixels:

Focal length Datasheet px/m Pinhole px/m Pinhole overstates by
2.8 mm 62.3 100.1 61 percent
4 mm 102.9 143.1 39 percent
6 mm 188.4 214.6 14 percent
8 mm 243.7 286.1 17 percent

The 4 mm row is the article's camera. It computed 142. The datasheet angle gives 102.9, and the other 1/2.7-inch model's 90.2 degrees gives 95.7. Call it a hundred, give or take five.

The shape of that table matters more than any single cell. At 2.8 mm the two methods disagree by 61 percent, because that is where the distortion is 63 percent. At 6 and 8 mm they agree to within a sixth, because those lenses barely bend. The wide end is not just wider; it is the end where the two ways of thinking about field of view stop being approximately the same thing.

This is why the 4 mm case is the one to argue about. It is the default lens on almost every cheap camera, it is the one in the worked example, and it sits at 68 degrees on one method and 86 on the other.

The four tiers, and how far each lens reaches

There is a standard scale for what a pixel density buys, and it removes the need to argue about whether 142 is enough. IEC 62676-4, and its European twin EN 62676-4, define four operational tiers: detect at 25 pixels per metre, observe at 62.5, recognise at 125, identify at 250.

The numbers are not arbitrary. Identification is anchored on a 16 cm human face occupying about 40 pixels across, and 0.16 m times 250 pixels per metre is 40 pixels. Everything else scales down from that anchor by factors of two and a half.

The 2025 amendment to the standard adds a second seven-step ladder alongside the four classic tiers, running from overview at 20 px/m to scrutinise at 1,500. The four DORI thresholds are unchanged, so designs drawn against them stay valid.

With the tiers fixed, each focal length turns into a set of maximum distances. Given a horizontal resolution and an angle, the distance at which density falls to a target is 1,920 divided by twice the target density times the tangent of half the angle:

Focal length Detect 25 Observe 62.5 Recognise 125 Identify 250
2.8 mm 24.9 m 10.0 m 5.0 m 2.5 m
4 mm 41.2 m 16.5 m 8.2 m 4.1 m
6 mm 75.4 m 30.1 m 15.1 m 7.5 m
8 mm 97.5 m 39.0 m 19.5 m 9.7 m

Run the same calculation on the pinhole angles and the identify column becomes 4.0, 5.7, 8.6 and 11.4 m. The 2.8 mm lens gains sixty percent of its identification range from the choice of formula. The 8 mm lens gains seventeen.

Pixel density at ten metres for four lenses, marked against the four DORI thresholds

Three of these cells land uncomfortably close to a threshold, and the closeness is the argument.

The 2.8 mm lens at ten metres delivers 62.3 pixels per metre. The observe tier is 62.5. The camera misses it by 0.2, which is a coincidence of this particular sensor and this particular distance rather than a designed margin, and it is exactly the kind of coincidence that makes a spreadsheet cell turn green when the site will not.

The 4 mm lens at ten metres delivers 102.9. That clears observe by a wide margin and misses recognise by 18 percent. The pinhole method's 143 clears recognise. So the same camera, at the same distance, is either comfortably above a tier or comfortably below it depending on which angle you believed.

The 8 mm lens at ten metres delivers 243.7. Identify is 250. It misses by 2.5 percent, which is inside the error of every other assumption in the chain, including the mounting angle and the compression setting.

Reading the scene table with those numbers

The scene table the article reproduces is eight rows long, and it holds up better than its shaky derivation would suggest. Checking each row against the DORI distances explains why.

Take the lift car. A typical cabin is 1.6 m wide and the camera sits about 2 m from the far wall. A 2.8 mm lens at 2 m covers 6.16 m, so the cabin fills 26 percent of the frame width, or about 499 of the 1,920 pixels. A 16 cm face at that distance gets 50 pixels across. That is above the identify anchor of 40, so 2.8 mm is correct here, and it is correct for a reason the table does not state: the camera is two metres from the subject.

Take the unit door at 6 mm. Identify range is 7.5 m and the table says 3 to 6 m. Inside the margin, correctly.

Take the perimeter wall at 8 mm, described as looking twenty metres out to see whether someone is climbing over. Detection range for 8 mm is 97.5 m, so twenty metres has five times the margin needed. Identification range is 9.7 m, so the same twenty metres is twice as far as the camera can identify anyone at. The row is right if the requirement is "is there a person there" and wrong by a factor of two if it is "who is that person". The table does not say which, and that omission is the whole problem with it.

Take the outdoor road at 6 to 8 mm, described as following the road out for tens of metres. At 30 m an 8 mm lens delivers 81 pixels per metre, which is just above observe. A face at 30 m is 13 pixels wide. At 40 m the density is 61 pixels per metre and the face is under 10 pixels. Both are enough to see that a vehicle stopped. Neither is enough to read a plate or a face, and "tens of metres" covers both 20 and 90.

Take the car park entrance at 8 to 12 mm, the one row where the table explicitly asks for plate reading. The article's own plate threshold is 300 to 400 pixels per metre. An 8 mm lens reaches 300 at 8.1 m and 400 at 6.1 m. A 12 mm lens, at a pinhole angle of 25.2 degrees, reaches 300 at 14.3 m. So the 8 to 12 mm range corresponds to a working distance of roughly six to fourteen metres, and if the barrier is eighteen metres from the camera the range is wrong at both ends.

The table works because most of its rows implicitly assume the tier that makes them true. The lift row assumes identify at two metres. The wall row assumes detect at twenty. The road row assumes observe at thirty. Written out that way, the table is a set of worked examples rather than a rule, and it stops being portable the moment your site's distances or requirements differ.

What the datasheet leaves out

Four quantities decide whether the calculation holds up on site, and none of them appear on the specification sheet.

The first is where the frame lands on the ground. With the camera at height H and tilted down by theta, the centre of the frame meets the ground at (H minus 1.5) divided by tan theta, taking 1.5 m as eye height. Raise the camera by a metre and that point moves outward by 1 divided by tan theta: 5.67 m at a ten degree tilt, 3.73 m at fifteen, 1.73 m at thirty. This is what "the camera covers less ground when you mount it higher" actually means. The angular coverage has not changed at all; the patch of ground it lands on has slid away from the wall.

The second is the cosine cubed law. A target that sits phi degrees off the optical axis has its vertical detail compressed by roughly cos cubed of phi, because the target is farther away, seen at a slant, and projected onto a plane that is tilted relative to the line of sight. At twenty degrees off axis the vertical density is 83 percent of the on-axis value. At thirty-five degrees it is 55 percent. Nobody mounts a camera with the target dead centre, so the number in the spreadsheet is an upper bound.

The third is the edge discount, and the lens datasheets hand it over almost by accident. A distortion figure of 63.4 percent means the outermost ring of the image holds objects at 36.6 percent of the magnification they would have at the centre. One degree of scene at the edge of a 2.8 mm lens uses 0.366 degrees' worth of pixels. The average density the formula produces is therefore split very unevenly: generous in the middle, thin at the corners. If the face you need to identify walks along the left edge of the frame, the 62 pixels per metre you calculated is not what is on that face.

The fourth is wobble. Optical image stabilisation is not standard on fixed cameras, and a pole in wind moves. A tenth of a degree of movement shifts the image by the focal length times the tangent of that angle, divided by the pixel pitch. At 1/2.7-inch and 1,920 pixels the pitch is 2.80 micrometres, so a tenth of a degree moves 2.5 pixels at 4 mm, 5.0 at 8 mm and 7.5 at 12 mm. A hundredth of a degree, which is a stiff pole on a calm day, moves a quarter of a pixel at 4 mm and half a pixel at 8 mm.

The fourth number is the one that makes the varifocal argument in the article's list of five mistakes more precise than the article had it. Long focal lengths do amplify movement, linearly and without drama: doubling the focal length doubles the pixel shift. What the article describes as shake appearing at maximum zoom is a 12 mm lens turning 0.1 degrees into 7.5 pixels of blur, against 2.5 for the 4 mm it replaced.

A method that works with either number

Since the field of view is the only input that matters and the camera sheet is the only place it is printed, the calculation can be rebuilt to use nothing else. Focal length and sensor format drop out entirely.

Start from the tier. Detection, observation, recognition or identification, expressed as 25, 62.5, 125 or 250 pixels per metre. There is no point carrying a number with more precision than that, because the tier is a task definition and not a measurement.

Convert the tier into a frame width. Divide the horizontal pixel count by the density. A 1,920-wide camera at identification needs 7.68 m of frame width.

Convert the frame width into a distance using the datasheet angle. Distance is half the frame width divided by the tangent of half the horizontal field of view. With a 4 mm lens at 86 degrees, 3.84 m divided by tan 43 degrees gives 4.12 m. That is the honest identification range of that camera, and it is 28 percent shorter than the 5.7 m the pinhole method would have promised.

Run the same chain backwards to pick a lens. For a target at distance d needing density p, the required angle is 2 arctan(1,920 / (2 d p)), and the lens whose datasheet angle is at or below that is the one to buy.

The article's own worked example lands on a useful snag here. It concludes that ten metres at 250 pixels per metre needs a 7 mm lens. On the pinhole method that is right: 7.68 m of frame width divided into ten metres of distance does come out at 6.99 mm. But 7 mm does not exist in the catalogue. The nearest lens is 8 mm, and 8 mm at 43 degrees covers 7.88 m at ten metres, which is 244 pixels per metre. The correct answer, purchaseable and verified, is 2.5 percent short of identification.

That is not a rounding complaint. It is what happens when a continuous calculation meets a discrete shelf, and it is why the last step of any focal length calculation has to be a re-check with the actual lens's actual angle.

What transfers

Three things carry over to any camera selection, whatever the sensor or the brand.

The first is that a quoted field of view is a measured property of a lens and a sensor together, not a derived one. If a sheet gives you an angle, use the angle. If it gives you only a focal length and a format, you are about to use a model that ignores distortion, and the error is 61 percent at the wide end and 17 percent at the long end.

The same arithmetic explains why swapping a camera without swapping its focal length changes the picture. A 4 mm lens on a 1/2.7-inch sensor covers 67.7 degrees; the same 4 mm on a 1/1.8-inch sensor, 7.18 mm wide, covers 83.8 degrees. The frame is 34 percent wider and the pixel density at the same distance drops 25 percent, because the same 1,920 pixels are spread over more ground.

The second is that pixel density is an average. It falls off toward the corners by the distortion figure, it falls off with distance, and it falls off faster when the camera is tilted and the target sits off axis. The single number in the spreadsheet is the best case.

The third is that the four tiers are the only part of the argument that is standardised. The focal lengths are a convention, the scene table is a set of examples, and the pixel density formula is a model with known error bars. The tiers are what a client, an auditor or a tender document will actually hold you to, and they are the only numbers in the chain that do not depend on which datasheet you opened.

The article's closing line, that after enough installations you carry a calculator in your head, is true in a specific way. What you carry is not the arithmetic. It is the knowledge that a 4 mm lens is not 68 degrees, and that the number printed on the box is the one the image will actually be.

← All news