-
-
Notifications
You must be signed in to change notification settings - Fork 259
Description
Currently, all coordinates are implemented as ints, which is perfectly fine for static pages.
The problem begins, when you begin to animate things. A perfectly smooth animation in a typical render loop is impossible using int output, since you always have frame time fractions, which lead to a jitter of the movement due to the conversion to int.
But I assume, litehtml often will be used as a UI support library, and at least in game UI smooth animation is crucial.
There could be a preprocessor switch for this, which could be set if you use float capable output like cairo and if you need it for animation, so that a coord_t could be either int or float/double.
The jitter effect is subtle, and I am not sure if it is worth the effort.
But smooth animations are a sign of quality at least in game development, and I wanted to post this just as a basis for discussion.