Skip to content

webgl: incorrect billboarding of thick lines #2488

Closed
@Spongman

Description

@Spongman

When the view is rotated, the segments of thick lines are not being billboarded correctly.

(also, the joins are not pretty, but that's a different bug)

image

function setup() {
  createCanvas(400, 400, WEBGL);
}

function draw() {
  background(0);
  rotateX(millis()/1000);
  noFill();
  stroke(255);
  strokeWeight(100);
  
  beginShape();
  vertex(-100, -100);
  vertex( 100, -100);
  vertex( 100,  100);
  vertex(-100,  100);
  endShape(CLOSE);
}

https://codepen.io/Spongman/pen/ppwQEj?editors=0010

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions