回答編集履歴

1

提示コードを修正

2022/01/30 01:31

投稿

退会済みユーザー
test CHANGED
@@ -1,7 +1,7 @@
1
1
  以下の式で実装出来ました。
2
2
 
3
- ```
3
+ ```cpp
4
- float xpos = (pos.x * screenSize.x) + ((float)screenSize.x / 2.0f) - 0.5f;
4
+ float xpos = (pos.x * screenSize.x) - 0.5f;
5
- float ypos = (pos.y * screenSize.y) - ((float)screenSize.y / 2.0f) - 0.5f;
5
+ float ypos = (pos.y * screenSize.y) - 0.5f;
6
6
 
7
7
  ```