[Unity] 타일 사이 흰색 줄 없애기 — Remove white line between tiles

Game Neo
2 min readSep 21, 2020

유니티 2019.4.4f1버젼으로 테스트 되었음. Tested unity version is 2019.4.4f1.

타일로 이미지를 채웠을때 위 이미지 처럼 각 타일 사이에 흰색 선이 나타나는 경우가 있다. When you use tiles, sometimes you can see white line between tiles in Unity.

인터넷에서 아래의 방법을 찾았으나 본인의 경우 동작하지 않았다.I found a solution below on the internet but it does not work for me.

  • Edit -> Project Setting -> Quality -> Anti Aliasing Disabled

그래서, Sprite Editor 에서 상하좌우 Border를 2px씩 줄여서 사용하는 방식으로 문제를 해결방법을 찾아냈다. However, I found the solution that reduces the upper, lower, left, and right borders by 2px in the Sprite Editor.

타일 사이 흰색 선을 없애는 솔루션. The Solution of removing white lines between tiles.

타일 이미지 제작 샘플 : 256 px * 256 px

Criteria for making tile image sample : 256 px * 256px

(1) 상하좌우에 제외할 부분(이미지의 경우 검정색)을 넣어 이미지를 만든다. Create an image by putting the parts to be excluded (black in the case of an image) in the top, bottom, left, and right.

(2) 실제 반복될 타일 이미지는 (실제 반복될 영역 : 회색)은 254 px * 254 px로 만든다. The tile image to be actually repeated (real area to be repeated: gray) is 254 px * 254 px.

(3) Sprite Editor 에서 각 사이드에 Border 를 2씩 넣어 검정색 부분 1px과 회색 영역 1 px을 잘라 낸다. (2px 중 회색 1px이 같이 반복되며, 흰색 선을 안 보이게 할 것이다.) In the Sprite Editor, put 2 Borders on each side and cut out 1 px of the black area and 1 px of the gray area. (Out of 2px, 1px of gray will be repeated, and the white line will not be visible.)

(4) Apply하고 보면 우리가 잘라낸 회색 1px이 겹쳐져 보이기 때문에 흰색 선이 더이상 나타나지 않는다. After applying, the gray 1px cut out appears overlapping, so the white line no longer appears.

이상 솔루션 완료! Solution complete

--

--