当前位置:网站首页>Interaction of Pico neo3 in Unity
Interaction of Pico neo3 in Unity
2022-08-11 07:52:00 【is a small A】
The last article talked about the movement of Pico neo3 in Unity. Today, I will explain how Pico neo3 interacts with UI pages in Unity3D. Many people think that using Pico devices for engine development is too troublesome, and they are not familiar with Pico.API usage, not very understanding of the interaction events of the UI page.
1. First import the Pico SDK into Unity, you can refer to my previous article Import of Pico SDK
2. Delete the Camera that comes with Unity, find the Pvr_UnitySDK subfolder Prefabs, drag the Pvr_UnitySDK prefab under the Prefabs folder into the scene, and the camera is ready, as shown below
Event is the event, Head is the head, EyeMask refers to the eyes of the Pico device, add the script Pvr_Input Module script to the Event, and set the Pico button of the Unity event and UI interaction event. The system defaults to the TouchPad button (that is, the rounded corners).Joystick), this is selected according to your own habits
3. Find the Scenes folder under the Pvr_Controller folder, open the Pvr_Controller_Demo scene in the Scenes folder, find the HeadControl sub-object of the Pvr_UnitySDK, put it in the Assets directory, and then return to the previous scene, the steps are as shown below
4. Put the HeadControl into the Pvr_UnitySDK to make it a child object, the same level as the Head, find the ControllerManager prefab in the Pvr_Controller folder and put it into the scene to become a child object of the Pvr_UnitySDK, which is the same as the Head and the Head in the Pvr_UnitySDK.HeadControl is at the same level, as shown below
5. Add the script Pvr_Controller Demo for ControllerManager, this script comes with PicoSDK, you can add it directly
Enable dot, ray_alpha, ray_LengthAdaptive of the child object of ControllerManager's child object PvrController0
Enable dot, ray_alpha, ray_LengthAdaptive of the child object of ControllerManager's child object PvrController1
Check the Length Adaptive Ray on the ControllerManager component, the specific operation steps are shown in the following figure
6. Create a Canvas, set the Render Mode property of Canvas to World Space, drag the sub-object Head of Pvr_UnitySDK into the Event Camera of Canvas, and add the script Pvr_UI Canvas(Script) to Canvas, this script is provided by PicoSDK,You can add it directly, the steps are as shown below
7. Set the Scale of Canvas to a ratio of 0.05 0.05 1, and create a Button component on Canvas for testing. The test results are as follows
Pico devices can interact with Unity's UI interface
Interaction of UI pages imported by PicoSDK
At this point, the Pico device can interact with Unity on the UI page normally
In the next article, I will share with you the API usage of PicoSDK, so as to complete the interactive operation of Pico handle event type
边栏推荐
- go-grpc TSL认证 解决 transport: authentication handshake failed: x509 certificate relies on ... ...
- CIKM 2022 AnalytiCup Competition: 联邦异质任务学习
- Service的两种状态形式
- TF中使用softmax函数;
- 【latex异常和错误】Missing $ inserted.<inserted text>You can‘t use \spacefactor in math mode.输出文本要注意特殊字符的转义
- Edge provides label grouping functionality
- 3GPP LTE/NR信道模型
- redis操作
- Pico neo3在Unity中的交互操作
- 软件测试主要做什么工作,难不难?
猜你喜欢
随机推荐
计算YUV文件的PSNR与SSIM
Unity3D learning route?
golang fork 进程的三种方式
【Pytorch】nn.PixelShuffle
软件测试主要做什么工作,难不难?
Tidb二进制集群搭建
Go语言实现Etcd服务发现(Etcd & Service Discovery & Go)
【LeetCode每日一题】——844.比较含退格的字符串
Waldom Electronics宣布成立顾问委员会
About # SQL problem: how to set the following data by commas into multiple lines, in the form of column display
【LaTex-错误和异常】\verb ended by end of line.原因是因为闭合边界符没有在\verb命令所属行中出现;\verb命令的正确和错误用法、verbatim环境的用法
项目2-年收入判断
NTT的Another Me技术助力创造歌舞伎演员中村狮童的数字孪生体,将在 “Cho Kabuki 2022 Powered by NTT”舞台剧中首次亮相
1002 Write the number (20 points)
1091 N-Defensive Number (15 points)
详述 MIMIC护理人员信息表(十五)
STM32CUBEIDE(11)----输出PWM及修改PWM频率与占空比
1071 小赌怡情 (15 分)
进制转换间的那点事
Item 2 - Annual Income Judgment