-
Notifications
You must be signed in to change notification settings - Fork 173
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
decomp: decompile trajectory
#499
Conversation
Pull Request Test Coverage Report for Build 855283245
💛 - Coveralls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think add-debug-line
might not be right but everything else looks good
) | ||
(let ((t2-0 -1)) | ||
) | ||
(t9-1 a0-6 a1-1 a2-1 a3-0 (the-as int t0-0) t1-0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
based on the code here, i'd guess that add-debug-line
takes one more argument (possibly unused inside the function).
If you try that, does this get a lot nicer?
(a1-1 68) | ||
(a2-1 s5-0) | ||
(a3-0 s4-0) | ||
(t0-0 #x800000ff) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like a rgba color to me. If you change the type of add-debug-line
to make this argument an rgba
, it should convert this to (new 'static 'rgba :r #xff :a #x80)
automatically.
;; Used lq/sq | ||
(defmethod TODO-RENAME-15 trajectory ((obj trajectory)) | ||
(let ((s5-0 (new 'stack-no-clear 'trajectory)) | ||
(s4-0 (new 'stack-no-clear 'trajectory)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm guessing these are vector
instead of trajectory?
cae30ba
to
44a6682
Compare
(defmethod | ||
TODO-RENAME-9 | ||
trajectory | ||
((obj trajectory) (arg0 float) (arg1 trajectory)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think arg1
here is a vector. Thie method does "evaluate trajectory at time arg0" and its output is just a vector
for the point.
(defmethod | ||
TODO-RENAME-10 | ||
trajectory | ||
((obj trajectory) (arg0 float) (arg1 trajectory) (arg2 trajectory)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think arg1
is a vector
and arg2
can be removed. This function computes the derivative of the trajectory and stores it in a vector
(arg2).
((method-of-type trajectory TODO-RENAME-9) | ||
obj | ||
f0-1 | ||
(the-as trajectory s4-0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Casting a to a larger type (trajectory > vector) is a sign that something isn't quite right here. I think once you change the arguments on this method it will go away.
I'm pretty confident about the signature for
add-debug-line
but might be worth an extra pair of eyes.