Home
Mobile
Internet
Server
Language
Enterprise
Database
News
Others
Search
3 turn 2 2 turn 3
Others
2022-04-22 04:58:23
views: 0
There is a perspective camera that illuminates 3D objects in the scene. NGUI uses its own independent orthogonal camera. The conversion steps are as follows:
1. Convert world coordinates to screen coordinates using a perspective camera
Vector3 pos = Camera.main.WorldToScreenPoint(worldPos);
pos.z = 0f; //z must be 0.
2. Use UI camera to convert to NGUI world coordinates
Vector3 pos2 = UICamera.currentCamera.ScreenToWorldPoint(pos);
3. Assignment to NGUI control
temp.transform.position = pos2;
//temp is an NGUI control.
//camera is different so it needs to be converted by screen coordinates
//Finally converted to 3d world coordinates, because the object hanging points are different, and the world 3d does not need to be calculated again
//z is 0 to prevent interference from 2 to 3
Guess you like
Origin
http://43.154.161.224:23101/article/api/json?id=324838875&siteId=291194637
3 turn 2 2 turn 3
[Turn] etcdctl v2 v3 Guide
Turn on the light problem 3_2 (JAVA language)
Turn: 2 pieces of life
-2 consumption turn android
The main difference Python2.x and Python3.x of (turn)
Turn: c/c++ unknown trap - 2 yuan, 3 yuan escape characters
LeetCode toss and turn plan (3)
[Turn] OpenGL Introduction - Lesson 3
[Turn] OpenGL Introduction - Lesson 2
turn!
Python3 Unicode turn Chinese
First: introduction of DDR3 and mig - turn
AnyCAD 3D Controls (turn)
[Turn] Zuul Advanced Configuration (zuul - 3)
[Turn] Pands (3) — Merge method is introduced in detail!
[Turn] css3 deformation attribute transform
[Turn] swagger2 Start Tutorial
Detailed I2C bus - turn
Add the fewest characters to turn the string into a palindrome (2)
Dapper official translation Tutorial 3: Query Dapper method of (turn)
cesium obj turn b3dm conversion and loading
wav mp3 format converter which turn good
C # WinForm program using Unity3D control (turn)
Turn: Raspberry Pi 3B + installation system
[Turn] CSS3 custom scroll bar style
Sublime Text3 For Mac Turn off Automatic Updates
Turn: Windows Azure Platform Experience (3): Azure AppFabric
Turn: [Python3 crawlers develop practical handle exceptions 3.1.2]
[Turn] 3 solution to Baidu network disk speed limit
Recommended
Ranking
Reason Codes enhanced accounting documents
The first test case appium
Force command and dispatch emergency communication plan
Interview - What is concurrent programming
21 classic Python interview questions [recommended collection]
[Dahua Data Structure-Introduction to Data Structure ①]
Spring @ConfigurationProperties
Why do we want to broadcast live on WeChat public account? What are the advantages?
How to bring up the toolbar under the desktop of Apple laptop
Dialog: Manually enter information
Daily
More
2024-05-21(35)
2024-05-20(5)
2024-05-19(0)
2024-05-18(31)
2024-05-17(6)
2024-05-16(23)
2024-05-15(5)
2024-05-14(9)
2024-05-13(8)
2024-05-12(28)