CARVIEW |
Select Language
HTTP/2 200
date: Sun, 27 Jul 2025 06:11:43 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
x-robots-tag: none
etag: W/"094ad5cf8ec71316a95256f3c99e82d9"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=rJ%2B2gR%2F5nY2bfqFMNal%2FtVrACLcBmG%2FcJdlSBM26VqAW4bfzisK%2BgwowRrix1Bik%2FMk%2F8f6jDBkEFghekb3o9EYcXBgUl3xctH2HkybdvBlehcH4twfIpuf%2FciQHzA6W6K1XCOlnttifDGsx233Sg52PE4%2FTDLE4yJc5NZEtfK%2FQYqFvZcBcQ6jSr6OGvHEn0mN4VdgJyX2Zg0dQoNtEY7uPZSVr59eWIKohIoRHmkfZkO2RMDpej7IcL0IYQzXXHVxVszLWHg5xvHxKcK4OAg%3D%3D--JNT5oyvgJbYPjKq9--D%2F9v58YeUdqJ%2FwI6zj0hvQ%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.1558750717.1753596703; Path=/; Domain=github.com; Expires=Mon, 27 Jul 2026 06:11:43 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Mon, 27 Jul 2026 06:11:43 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: 88B0:5FFA9:B63685:F2241E:6885C31F
CurveInterpolator · swgpu/SWGPU Wiki · GitHub
Skip to content
Navigation Menu
{{ message }}
-
Notifications
You must be signed in to change notification settings - Fork 1
CurveInterpolator
jay19240 edited this page Dec 11, 2024
·
2 revisions
Cubic curve interpolator
-
new CurveInterpolator(points: Vector[], options: CurveInterpolatorOptions): default
- points: control points
- options: curve interpolator options
-
createLookupTable(func, samples: number, options): Map
- func: function generating lookup table value
- samples: number of samples (segments)
- options: object of { from, to, cacheKey } - if cacheKey is included, the map will be stored in the internal cache
-
forEach(func, samples, from: number, to: number): void
- func: callback function
- samples: number of (evenly spaced) samples OR an array of user specified positions (u)
- from: from position
- to: to position
-
getBoundingBox(from: number, to: number): BBox
- from: position from
- to: position to
-
getCurvatureAt(position: number)
- position: position on curve (0 - 1)
-
getCurvatureAtTime(t: number)
- t: time (t) along curve (0 - 1)
-
getDerivativeAt(position: number, target: T): T
- position: position on curve (0 - 1)
- target: optional target
-
getFrenetFrames(segments: number, from: number, to: number)
- segments: number of samples (segments) along the curve (will return segments + 1 frames)
- from: position from
- to: position to
-
getIntersects(v: number, axis: number, max: number, margin: number)
- v: lookup value
- axis: index of axis [0=x, 1=y, 2=z ...]
- max: max solutions (i.e. 0=all, 1=first along curve, -1=last along curve)
- margin
-
getIntersectsAsPositions(v: number, axis: number, max: number, margin: number)
- v: lookup value
- axis: index of axis [0=x, 1=y, 2=z ...]
- max: max solutions (i.e. 0=all, 1=first along curve, -1=last along curve)
- margin
-
getIntersectsAsTime(v: number, axis: number, max: number, margin: number)
- v: lookup value
- axis: index of axis [0=x, 1=y, 2=z ...]
- max: max solutions (i.e. 0=all, 1=first along curve, -1=last along curve)
- margin
-
getLengthAt(position: number, clampInput: boolean): number
- position: position on curve (0..1)
- clampInput
-
getNearestPosition(point: Vector, threshold: number, samples: number)
- point: Vector
- threshold: Precision
- samples
-
getNormalAt(position: number, target: T): T
- position: position on curve (0 - 1)
- target: optional target
-
getNormalAtTime(t: number, target: T): T
- t: time at curve (0 - 1)
- target: optional target
-
getPointAt(position: number, target: T): T
- position: position on curve (0..1)
- target: optional target
-
getPointAtTime(t: number, target: VectorType): Vector
- t: time along full curve (encodes segment index and segment t)
- target: optional target vector
-
getPoints(segments: number, returnType)
- segments: number of samples (segments)
- returnType: optional return type
-
getPositionAtKnot(index: number): number
- index: index of knot (control/input point)
-
getPositionFromLength(length: number, clampInput: boolean): number
- length
- clampInput: whether the input value should be clamped to a valid range or not
-
getPositionFromTime(t: number, clampInput: boolean): number
- t: time on curve (0..1)
- clampInput: whether the input value should be clamped to a valid range or not
-
getSecondDerivativeAt(position: number, target: T): T
- position: position on curve (0 - 1)
- target: optional target
-
getTangentAt(position: number, target: T): T
- position: position on curve (0 - 1)
- target: optional target
-
getTangentAtTime(t: number, target: T): T
- t: time at curve (0 - 1)
- target: optional target
-
getTimeAtKnot(index: number): number
- index: index of knot (control/input point)
-
getTimeFromPosition(position: number, clampInput: boolean): number
- position: position on curve (0..1)
- clampInput: whether the input value should be clamped to a valid range or not
-
map(func, samples, from: number, to: number)
- func: mapping function
- samples: number of (evenly spaced) samples OR an array of user specified positions (u)
- from: from position
- to: to position
-
reduce(func, initialValue: T, samples, from: number, to: number): T
- func: reduce function
- initialValue: initial accumulator value
- samples: number of (evenly spaced) samples OR an array of user specified positions (u)
- from: from position
- to: to position
- reset(): void
Clone this wiki locally
You can’t perform that action at this time.