Skip to content

Commit bcf5a8a

Browse files
committed
Fix round
1 parent abbc548 commit bcf5a8a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

coloraide/spaces/ycbcr709.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def digital_round(self, x: float) -> int:
7676
Clamping is then applied to keep the value within the target integer type.
7777
"""
7878

79-
return alg.clamp(int(alg.sign(x) * math.floor(abs(x) + 5)), 0, self.max_integer_size)
79+
return alg.clamp(int(alg.sign(x) * math.floor(abs(x) + 0.5)) 0, self.max_integer_size)
8080

8181

8282
class YPbPr(Labish, Space):

0 commit comments

Comments
 (0)