Handles
- ArrowCap
- BeginGUI
- Button
- CircleCap
- ClearCamera
- color
- ConeCap
- CubeCap
- currentCamera
- CylinderCap
- Disc
- DotCap
- DrawAAPolyLine
- DrawBezier
- DrawCamera
- DrawCapFunction
- DrawLine
- DrawPolyLine
- DrawSolidArc
- DrawSolidDisc
- DrawSolidRectangleWithOutline
- DrawWireArc
- DrawWireDisc
- EndGUI
- FreeMoveHandle
- FreeRotateHandle
- Label
- lighting
- matrix
- PositionHandle
- RadiusHandle
- RectangleCap
- RotationHandle
- ScaleHandle
- ScaleSlider
- ScaleValueHandle
- SetCamera
- Slider2D
- Slider
- SnapValue
- SphereCap
Handles.Slider2D 二维滑动柄
static function Slider2D (handlePos : Vector3, handleDir : Vector3, slideDir1 : Vector3, slideDir2 : Vector3, handleSize : float, drawFunc : DrawCapFunction, snap : float, drawHelper : bool = false) : Vector3
Parameters参数
- handlePosthe position of the current point. // 当前位置
- handleDirthe direction of the handle, only used for rendering of the handle
控制柄的方向,仅用于控制柄渲染。 -
slideDir1the first direction of the sliding. // 滑动第一方向。
-
slideDir2the second direction of the sliding. // 滑动第二方向。
-
handleSizethe size of the handle - HandleUtility.GetHandleSize (position);
控制柄的大小 -
drawFuncthe function to call for doing the actual drawing - by default, it's Handles.ArrowCap, but any function that has the same signature can be used.
调用函数来用于实际的绘制,默认是Handles.ArrowCap,但任意函数具有相同的签名可以被使用。 -
snapuse snapping (uses SnapSettings.scale)
使用捕捉 -
drawHelperrender a rectangle around the handle when dragging
拖动时围绕控制柄渲染一个矩形。
Vector3 - the new handle position Note: Use HandleUtility.GetHandleSize where you might want to have constant screen-sized handles.
返回三维向量,新的控制柄位置。注意,使用HandleUtility.GetHandleSize你可能希望有恒定的屏幕大小的控制柄。
Description描述
Slide a handle in a 2D plane
在2D平面的滑动控制柄。
This will draw a draggable handle on the screen. The handle is constrained to sliding on a plane.
这将在屏幕上绘制一个可拖动控制柄。控制是被约束在一个平面上滑动。
最后修改:2011年7月9日 Saturday 17:05