当前位置: 首页>>代码示例>>C#>>正文


C# HandModel类代码示例

本文整理汇总了C#中HandModel的典型用法代码示例。如果您正苦于以下问题:C# HandModel类的具体用法?C# HandModel怎么用?C# HandModel使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


HandModel类属于命名空间,在下文中一共展示了HandModel类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: CreateHand

 HandModel CreateHand(HandModel model) {
   HandModel hand_model = Instantiate(model, transform.position, transform.rotation)
                          as HandModel;
   hand_model.gameObject.SetActive(true);
   IgnoreHandCollisions(hand_model);
   return hand_model;
 }
开发者ID:VentorLee,项目名称:unity,代码行数:7,代码来源:HandController.cs

示例2: Start

 void Start()
 {
 	handmodel = GetComponent<HandModel>();
     _grabedObj = null;
     palmPostion = handmodel.GetPalmPosition();
     velocity = Vector3.zero;
 }
开发者ID:pangaeastudio,项目名称:vrgame-bruceli,代码行数:7,代码来源:LeapMotionHand.cs

示例3: EmitHand

 protected void EmitHand(HandModel value = null)
 {
     EventHandler<LMWidgets.EventArg<HandData>> handler = HandEvent;
                 if (handler != null) {
                         handler (this, new LMWidgets.EventArg<HandData> (new HandData (value)));
                 }
 }
开发者ID:ryanwang,项目名称:VR-Planetarium,代码行数:7,代码来源:HandEmitter.cs

示例4: Start

    public void Start()
    {
        if (!LeapHandController)
            throw new System.Exception("Leap Hand Controller has not been assigned!");

        _handModel = Utilities.GetHandModel(LeapHandController, HandModelType);
    }
开发者ID:sathiyavrs,项目名称:leap-learning,代码行数:7,代码来源:PlayerController.cs

示例5: IsReadyToCastBolts

	bool IsReadyToCastBolts(HandModel leftHand, HandModel rightHand){
		
		//Debug.Log (HandRecog.PalmsFacingEachOther (handController, leftHand, rightHand, palmDirMinAngle));

		return HandRecog.PalmsFacingEachOther (handController, leftHand, rightHand, palmDirMinAngle) &&
			HandRecog.IsHandClenchingStrict (leftHand, handClenchingMinAngle) && HandRecog.IsHandClenchingStrict (rightHand, handClenchingMinAngle);
	}
开发者ID:xzs424,项目名称:Mage-Simulator-Wizard-Adventure,代码行数:7,代码来源:MageThunderHandController.cs

示例6: Start

    // Use this for initialization
    void Start()
    {
        Current_Hand = new HandAttributes();

        cur_hand_model = transform.GetComponent<HandModel>();
        handInFrame = false;
        //   Debug.Log(cur_hand_model.name);
    }
开发者ID:irushavm,项目名称:LeapALittle,代码行数:9,代码来源:HandAttributes.cs

示例7: DistanceBetweenPalms

	public static float DistanceBetweenPalms(HandModel handOne, HandModel handTwo){

		Vector3 handOnePalmPos = handOne.GetPalmPosition();
		Vector3 handTwoPalmPos = handTwo.GetPalmPosition ();

		return Math3dExt.Distance (handOnePalmPos, handTwoPalmPos);

	}
开发者ID:xzs424,项目名称:Mage-Simulator-Wizard-Adventure,代码行数:8,代码来源:HandRecog.cs

示例8: DirectionBetweenPalm

	public static Vector3 DirectionBetweenPalm(HandModel fromHand, HandModel toHand){

		Vector3 fromHandPalmPos = fromHand.GetPalmPosition ();
		Vector3 toHandPalmPos = toHand.GetPalmPosition ();

		return Math3dExt.Direction (fromHandPalmPos, toHandPalmPos);

	}
开发者ID:xzs424,项目名称:Mage-Simulator-Wizard-Adventure,代码行数:8,代码来源:HandRecog.cs

示例9: GetFireBallSpawnPosition

	Vector3 GetFireBallSpawnPosition(HandModel hand, float distance){

		Vector3 palmPos = hand.GetPalmPosition ();

		Vector3 palmDir = hand.GetPalmNormal ();

		return palmPos + Vector3.Scale(palmDir,new Vector3(distance,distance,distance));
	}
开发者ID:xzs424,项目名称:Mage-Simulator-Wizard-Adventure,代码行数:8,代码来源:MageFireHandController.cs

示例10: GetAllGraphicsHands

    public HandModel[] GetAllGraphicsHands()
    {
        if (hand_graphics_ == null)
          return new HandModel[0];

        HandModel[] models = new HandModel[hand_graphics_.Count];
        hand_graphics_.Values.CopyTo(models, 0);
        return models;
    }
开发者ID:AjayTalati,项目名称:BCI_Experiments,代码行数:9,代码来源:HandController.cs

示例11: FirstRightHand

        HandModel FirstRightHand(HandModel[] handsInScene)
        {
            foreach (HandModel hand in handsInScene) {
                                if (hand.GetLeapHand ().IsRight)
                                        return hand;
                        }

                        return null;
        }
开发者ID:ryanwang,项目名称:VR-Planetarium,代码行数:9,代码来源:GetRightHand.cs

示例12: Awake

  protected virtual void Awake() {
    _handModel = GetComponent<HandModel>();
    _renderer = GetComponentInChildren<Renderer>();

    _fadePropertyBlock = new MaterialPropertyBlock();
    _renderer.GetPropertyBlock(_fadePropertyBlock);
    _fadePropertyBlock.SetFloat("_Fade", 0);
    _renderer.SetPropertyBlock(_fadePropertyBlock);
  }
开发者ID:CMPUT302-W2016,项目名称:HCI-Gestures,代码行数:9,代码来源:HandFader.cs

示例13: IsHand

 private bool IsHand(Collider other)
 {
     if (other.transform.parent && other.transform.parent.parent && other.transform.parent.parent.GetComponent<HandModel> ()) {
         _HandModel = other.transform.parent.parent.GetComponent<HandModel> ();
         return true;
     } else {
         _HandModel = null;
         return false;
     }
 }
开发者ID:SebastienBinet,项目名称:Unity3D_LeapMotion_SomeTests001,代码行数:10,代码来源:SebLevelActivator.cs

示例14: IsHandPresent

    private bool IsHandPresent()
    {
        if (!_handModel)
            _handModel = Utilities.GetHandModel(LeapHandController, HandModelType);

        if (_handModel == null)
            return false;

        return true;
    }
开发者ID:sathiyavrs,项目名称:leap-learning,代码行数:10,代码来源:PlayerController.cs

示例15: Fire

    IEnumerator Fire(HandModel currentHand)
    {
        canFire = false;
        //Debug.Log (canFire);

        GameObject justFired = Instantiate (ammo, currentHand.transform.position + currentHand.GetPalmNormal() * offset , currentHand.GetPalmRotation()) as GameObject;
        justFired.GetComponent<moveProjectile> ().target = target;
        //justFired.GetComponent<moveProjectile> ().force = Quaternion.LookRotation( handController.transform.forward, Vector3.down).eulerAngles;
        yield return new WaitForSeconds (delay);
            canFire = true;
    }
开发者ID:VRWizards,项目名称:VRWizards,代码行数:11,代码来源:Shoot.cs


注:本文中的HandModel类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。