Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 4135cf0

Browse files
Mike KleinSkia Commit-Bot
authored andcommitted
use round() instead of trunc() to f32->unorm
This does open us up to a little bit of possible inconsistency of rounding when right on a x.5 (sometimes we'll +0.5 and trunc, sometimes round to nearest, sometimes round according to the default mode which is usually round to nearest) but I think that inconsistency may be worth the free register not needing a splat(0.5f) buys us. A few invisible diffs. Change-Id: I9af092c937ccf7c5891c2ab3cb298d217e4a9e9f Reviewed-on: https://skia-review.googlesource.com/c/skia/+/253725 Commit-Queue: Mike Klein <mtklein@google.com> Reviewed-by: Mike Reed <reed@google.com>
1 parent b30d481 commit 4135cf0

File tree

3 files changed

+279
-299
lines changed

3 files changed

+279
-299
lines changed

0 commit comments

Comments
 (0)