https://github.com/dmnsgn/inverse-smoothstep
The inverse of the smoothstep function.
https://github.com/dmnsgn/inverse-smoothstep
interpolation inverse-smoothstep smoothstep
Last synced: 3 months ago
JSON representation
The inverse of the smoothstep function.
- Host: GitHub
- URL: https://github.com/dmnsgn/inverse-smoothstep
- Owner: dmnsgn
- License: mit
- Created: 2024-03-23T23:21:51.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-07-06T14:11:15.000Z (almost 2 years ago)
- Last Synced: 2025-09-28T14:49:52.437Z (8 months ago)
- Topics: interpolation, inverse-smoothstep, smoothstep
- Language: JavaScript
- Homepage: https://dmnsgn.github.io/inverse-smoothstep/
- Size: 237 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# inverse-smoothstep
[](https://www.npmjs.com/package/inverse-smoothstep)
[](https://www.npmjs.com/package/inverse-smoothstep)
[](https://bundlephobia.com/package/inverse-smoothstep)
[](https://github.com/dmnsgn/inverse-smoothstep/blob/main/package.json)
[](https://github.com/microsoft/TypeScript)
[](https://conventionalcommits.org)
[](https://github.com/prettier/prettier)
[](https://github.com/eslint/eslint)
[](https://github.com/dmnsgn/inverse-smoothstep/blob/main/LICENSE.md)
The inverse of the smoothstep function.
[](https://paypal.me/dmnsgn)
[](https://commerce.coinbase.com/checkout/56cbdf28-e323-48d8-9c98-7019e72c97f3)
[](https://twitter.com/dmnsgn)
Based on [Inigo Quilez](https://iquilezles.org/articles/ismoothstep/).

## Installation
```bash
npm install inverse-smoothstep
```
## Usage
```js
import inverseSmoothstep from "inverse-smoothstep";
inverseSmoothstep(0.5);
// => 0.5
inverseSmoothstep(0.75)
// => 0.6736481776669303
```
## API
## inverseSmoothstep
### inverseSmoothstep(x) ⇒ number ⏏
The inverse of the smoothstep function
**Kind**: Exported function
| Param | Type |
| ----- | ------------------- |
| x | number |
## License
MIT. See [license file](https://github.com/dmnsgn/inverse-smoothstep/blob/main/LICENSE.md).