Comments (1)
You are right, that's a leftover from the very first version of 4klang where a generic power function was called with the base provided by the caller.
Same applies to the comments.
It should be safe to modify it, as you already said.
I'll update the repo, once i checked all the recent incoming comments/bugs.
Thanks for the hint!
P.S:
The original function looked like this:
; //----------------------------------------------------------------------------------------
; // Power function
; //----------------------------------------------------------------------------------------
; // Input : st0 : base
; // st1 : exponent
; // Output: st0 : result
; //----------------------------------------------------------------------------------------
go4kPower: ; // base exp
fyl2x ; // log2_base -
fld st0 ; // log2_base log2_base
frndint ; // (int)log2_base log2_base
fxch ; // log2_base (int)log2_base
fsub st0, st1 ; // (frac)log2_base (int)log2_base
f2xm1 ; // 2 ^ '' - 1 (int)log2_base
fld1 ; // 1 2 ^ '' - 1 (int)log2_base
faddp st1, st0 ; // 2 ^ '' (int)log2_base
fscale
fstp st1
ret
from 4klang.
Related Issues (9)
- Why is the gate oscillator low-pass filtered HOT 3
- Save the commit SHA of the synth build used to generate .inc/.h files into a comment at the top
- Add Release Tags with Binary Builds HOT 1
- Offset into delay buffer gets corrupted for some builds HOT 1
- 64 bit player?
- Crashes during export (3.2.2-master) HOT 1
- Incorrect GO4K_FSTG_ID when exporting songs that don't use glitch
- Unnecessary code: short jump to next line HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from 4klang.