calculate position


calculate position

Author
Message
nakayama
nakayama
Distinguished Member
Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)Distinguished Member (2.7K reputation)

Group: Forum Members
Posts: 64, Visits: 374
Hi Dave,
i wish to use pixel to calculate the position and I am aware anything in expressions has no unit so I add*1px,
But the stimulus still did not show, How could i fix this (the screen resolution is 1960*1200, and "960", "1000", "65" are all in pixel)
thank youWink
Attachments
text4.iqx (5 views, 585 bytes)
Dave
Dave
Supreme Being
Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)Supreme Being (749K reputation)

Group: Administrators
Posts: 9.9K, Visits: 49K
nakayama - 11/4/2019
Hi Dave,
i wish to use pixel to calculate the position and I am aware anything in expressions has no unit so I add*1px,
But the stimulus still did not show, How could i fix this (the screen resolution is 1960*1200, and "960", "1000", "65" are all in pixel)
thank youWink

The first term in the calculation determines the unit, so it needs to be:

<expressions>
/circle_a= 1px*(values.circle_r/sin(1.5708))
/ circle_b=1px*((values.circle_r+values.circle_r*sin(1.5708))/tan(0.174533))
/ circle_x1=1px*(960-expressions.circle_a)
/circle_y1=1px*(1000-expressions.circle_b)
</expressions>

GO


Reading This Topic


Login
Existing Account
Email Address:


Password:


Social Logins

Select a Forum....






Millisecond Forums


Search