Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CurvePath: Use correct line type in closePath(). #26850

Merged
merged 2 commits into from
Sep 27, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/extras/core/CurvePath.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ class CurvePath extends Curve {

if ( ! startPoint.equals( endPoint ) ) {

this.curves.push( new Curves[ 'LineCurve' ]( endPoint, startPoint ) );
const lineType = ( startPoint.isVector2 === true ) ? 'LineCurve' : 'LineCurve3';
this.curves.push( new Curves[ lineType ]( endPoint, startPoint ) );

}

Expand Down