How to Convert Pixel to Point on the Server in Vue PDF Viewer

14 Aug 20261 minute to read

The PDF Viewer returns annotation bounds in pixels on the client side. To use them on the server side, convert pixels to points using the calculation below. The 0.75 multiplier (72/96) is the standard point-to-pixel ratio used for all server-side calculations.

X = x * 72 / 96
Y = y * 72 / 96
Width = width * 72 / 96
Height = height * 72 / 96