init grab position
This commit is contained in:
parent
ca4b715130
commit
28e1d81aeb
2 changed files with 6 additions and 5 deletions
|
@ -15,9 +15,9 @@ public class Grab
|
||||||
private Quat ori_offset;
|
private Quat ori_offset;
|
||||||
private Hand? held_by;
|
private Hand? held_by;
|
||||||
|
|
||||||
public Grab()
|
public Grab(float x, float y, float z)
|
||||||
{
|
{
|
||||||
pose = new Pose();
|
pose = new Pose(x, y, z);
|
||||||
pos_offset = Vec3.Zero;
|
pos_offset = Vec3.Zero;
|
||||||
ori_offset = Quat.Identity;
|
ori_offset = Quat.Identity;
|
||||||
held_by = null;
|
held_by = null;
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
using System;
|
||||||
using StereoKit;
|
using StereoKit;
|
||||||
|
|
||||||
namespace dofdemo;
|
namespace dofdemo;
|
||||||
|
@ -13,8 +14,8 @@ static class Stretch
|
||||||
|
|
||||||
public static void Init()
|
public static void Init()
|
||||||
{
|
{
|
||||||
to_grab = new();
|
to_grab = new(-0.3f, 0, 0);
|
||||||
from_grab = new();
|
from_grab = new(-0.3f, 0, 0.1f);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void Frame()
|
public static void Frame()
|
||||||
|
@ -42,7 +43,7 @@ static class ColorCube
|
||||||
|
|
||||||
public static void Init()
|
public static void Init()
|
||||||
{
|
{
|
||||||
grab = new();
|
grab = new(0, 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void Frame()
|
public static void Frame()
|
||||||
|
|
Loading…
Add table
Reference in a new issue