瀏覽代碼

Fix a visual glitch where the label border was initially rendered with
half of the intended size.

Michal Malý 3 年之前
父節點
當前提交
de77f6ac59
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/mol-geo/geometry/text/text.ts

+ 1 - 1
src/mol-geo/geometry/text/text.ts

@@ -245,7 +245,7 @@ export namespace Text {
             ...BaseGeometry.createValues(props, counts),
             uSizeFactor: ValueCell.create(props.sizeFactor),
 
-            uBorderWidth: ValueCell.create(clamp(props.borderWidth / 2, 0, 0.5)),
+            uBorderWidth: ValueCell.create(clamp(props.borderWidth, 0, 0.5)),
             uBorderColor: ValueCell.create(Color.toArrayNormalized(props.borderColor, Vec3.zero(), 0)),
             uOffsetX: ValueCell.create(props.offsetX),
             uOffsetY: ValueCell.create(props.offsetY),