diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-05-20 17:50:41 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-05-20 17:50:41 +0400 |
commit | 363bfdc46a05a5225bd4abc76b14ba2002f414af (patch) | |
tree | 5ffc73ffa68976711eebfc3770542a9df9287cd8 /source/blender/editors/include/ED_view3d.h | |
parent | a8ef6ffd170f559a50791556160fc3d7ec6a54d8 (diff) |
use consistant arguments to ED_view3d_win_* funcs, a single float vector rather then 2 floats.
Diffstat (limited to 'source/blender/editors/include/ED_view3d.h')
-rw-r--r-- | source/blender/editors/include/ED_view3d.h | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/source/blender/editors/include/ED_view3d.h b/source/blender/editors/include/ED_view3d.h index 1adf7c9000b..2f99cf16093 100644 --- a/source/blender/editors/include/ED_view3d.h +++ b/source/blender/editors/include/ED_view3d.h @@ -85,33 +85,30 @@ int initgrabz(struct RegionView3D *rv3d, float x, float y, float z); * Calculate a 3d location from 2d window coordinates. * @param ar The region (used for the window width and height). * @param depth_pt The reference location used to calculate the Z depth. - * @param mx The area relative X location (such as event->mval[0]). - * @param my The area relative Y location (such as event->mval[1]). + * @param mval The area relative location (such as event->mval converted to floats). * @param out The resulting world-space location. */ -void ED_view3d_win_to_3d(struct ARegion *ar, const float depth_pt[3], const float mx, const float my, float out[3]); +void ED_view3d_win_to_3d(struct ARegion *ar, const float depth_pt[3], const float mval[2], float out[3]); /** * Calculate a 3d difference vector from 2d window offset. * note that initgrabz() must be called first to determine * the depth used to calculate the delta. * @param ar The region (used for the window width and height). - * @param mx The area relative X difference (such as event->mval[0] - other_x). - * @param my The area relative Y difference (such as event->mval[1] - other_y). + * @param mval The area relative 2d difference (such as event->mval[0] - other_x). * @param out The resulting world-space delta. */ -void ED_view3d_win_to_delta(struct ARegion *ar, const float mx, const float my, float out[3]); +void ED_view3d_win_to_delta(struct ARegion *ar, const float mval[2], float out[3]); /** * Calculate a 3d direction vector from 2d window coordinates. * This direction vector starts and the view in the direction of the 2d window coordinates. * In orthographic view all window coordinates yield the same vector. * @param ar The region (used for the window width and height). - * @param mx The area relative X difference (such as event->mval[0]). - * @param my The area relative Y difference (such as event->mval[1]). + * @param mval The area relative 2d location (such as event->mval converted to floats). * @param out The resulting normalized world-space direction vector. */ -void ED_view3d_win_to_vector(struct ARegion *ar, const float mx, const float my, float out[3]); +void ED_view3d_win_to_vector(struct ARegion *ar, const float mval[2], float out[3]); /** * Calculate a 3d segment from 2d window coordinates. |