일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
- DS4
- unityhub
- web3D
- apk
- Unity VisualStudio
- Unity
- kinect v2
- Environment Reflections
- webview
- 반응형레이아웃
- 커스텀쉐이더
- 유니티
- muilt controller
- AssetBundle
- android app bundle
- WebGL
- TextMeshPro 한글
- 에셋번들
- 역직렬화 오류
- Android
- Depth camera
- untiy
- 듀얼쇼크4
- Specular Highlights
- 랜더스트리밍
- 구글플레이스토어
- AR
- Rewired
- TextMeshPro
- RenderStreaming
- Today
- Total
목록Unity (42)
기억저장고
Html파일에서 추가하기 window.devicePixelRatio = 1; 위치) var script = document.createElement("script"); var myGameInstance = null; script.src = loaderUrl; script.onload = () => { createUnityInstance(canvas, config, (progress) => { progressBarFull.style.width = 100 * progress + "%"; }).then((unityInstance) => { window.devicePixelRatio = 1;//이것!... myGameInstance = unityInstance; loadingBar.style.display = ..

유니티 App.... Target API 33 이상으로 올렸을때 문제 (1) 바로꺼지는 문제 - API31 폰에서는 잘 열리는데, API33 폰에서는 바로 꺼짐(로고도 안나오고 바로꺼짐) *테스트방법 1. SDK 문제인지 확인하기 > 빈 프로젝트 만들고, 안드로이드로 빌드해서 넣었을때 되면 SDK 문제 아님 ... > SDK > platforms에 들어가서 Target API까지 SDK가 안깔려있으면 빌드하고 오류날 수 있으므로 Android STudio 에서 SDK 다운받아놓기 2. 플러그인 문제 확인 > 기존에 사용했던 플러그인 폴더를 빈프로젝트에 넣고 빌드해서 넣어보기 > 테스트 시, 최상위의 Plugins폴더 말고 속속에 들어있는 Plugins 폴더들의 문제일 수 있으므로 잘 확인하기 *해결방법 ..
타켓 오브젝트가 카메라 오브젝트와 서로 마주보고 있지 않을때 카메라 FOV로 Zoom을 하면 카메라 기준으로만 Zoom이 된다 using UnityEngine; public class ObjectZoom : MonoBehaviour { public Transform targetObject; public float zoomSpeed = 2.0f; public float minZoom = 1.0f; public float maxZoom = 10.0f; void Update() { float scroll = Input.GetAxis("Mouse ScrollWheel"); // 현재 카메라 위치에서 타겟 오브젝트까지의 벡터를 계산합니다. Vector3 toTarget = targetObject.position ..
using System.Collections; using System.Collections.Generic; using UnityEngine; public class ObjectRotation : MonoBehaviour { public float rotationSpeed = 15;//회전속도 public float smoothness = 5;//관성 값 private Quaternion targetRotation = Quaternion.identity; void Update() { //회전 if (Input.GetMouseButton(0)) { Quaternion rot = transform.rotation; rot *= Quaternion.Euler(new Vector3(Input.GetAxis("Mo..
private void SettingTextWidth(RectTransform rectTrf,TextMeshProUGUI tmpText, string textValue) { tmpText.text = textValue; Vector2 rectSize = rectTrf.sizeDelta; rectSize.x = tmpText.preferredWidth; rectTrf.sizeDelta = rectSize; } preferredWidth 를 사용하면 길이를 알 수 있다!.. 출처 https://polarbearworld.tistory.com/167 Unity & C# ~ TMPRO에서 텍스트 길이 아는 법 TMPRO에서는 UI의 길이뿐 아니라, 현재 사용한 텍스트의 길이를 확인할 수 있는 명령어가 있다. u..
카메라 360 회전 시, X,Y값을 한번에 Rotate()함수 에 넣어야 똑바로 회전함 > 똑바로회전: 좌우 드래그시, 좌우로 회전되고/ 위아래 드래그시 위아래로 회전됨 public float rotationSpeed = 1; private float x = 0; private float y = 0; void Update() { if (Input.GetMouseButton(0)) { transform.Rotate(new Vector3(Input.GetAxis("Mouse Y") * rotationSpeed, -Input.GetAxis("Mouse X") * rotationSpeed, 0)); x = transform.rotation.eulerAngles.x; y = transform.rotation.eu..

1. 폰트 다운받기 2. 폰트오른쪽클릭>Create>TextMeshPro>Font Asset 클릭 끝.. ** 사용하는 글자가 깨지면 TMP_Font Asset 클릭 > Altas Width,Altas Height 값 더 크게 수정 (1024>2048...)

-쉐이더 코드에 이것 추가하면 된다. [ ToggleUI ] _CastShadows ( "Cast Shadows" , Float ) = 1.0 하지만,, Lux/Glass는 안먹힌다 그래서 Lux/Glass를 사용할때는 머터리얼을 2개 넣어줘야한다. [Lux/Glass에 그림자 추가하는방법] MeshRender의 Material에 아래와 같이 추가하면 그림자도 생기고 투명굴절도 생긴다. -Lux/Glass -Universal Renderpipline/Lit [출처] https://forum.unity.com/threads/shadows-not-casting-with-lwrp-lit-shader-transparent-surface.759827/#post-8181353 Shadows not casting w..