Skip to content

Commit

Permalink
Update webgpu_compute.html
Browse files Browse the repository at this point in the history
  • Loading branch information
LeviPesin authored Apr 26, 2022
1 parent 6417825 commit d4cbbee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/webgpu_compute.html
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@
const pointer = uniform( pointerVector );
const limit = uniform( scaleVector );

const position = temp( vec3() );
assign( position, add( particle, velocity ) ).build( builder ); // workaround
const position = temp( add( particle, velocity ) );
position.build( builder );

assign( velocity.x, cond( greaterThanEqual( abs( position.x ), limit.x ), negate( velocity.x ), velocity.x ) ).build( builder );
assign( velocity.y, cond( greaterThanEqual( abs( position.y ), limit.y ), negate( velocity.y ), velocity.y ) ).build( builder );
Expand Down

0 comments on commit d4cbbee

Please sign in to comment.