Version: 5.4
플레어
트레일 렌더러

라인 렌더러

라인 렌더러(Line Renderer) 컴포넌트는 3D 공간에서 두 개 이상 지점의 배열을 사용하고 각각을 연결하는 직선을 그립니다. 따라서 하나의 라인 렌더러 컴포넌트는 단순한 직선에서 시작해서 복잡한 곡선까지 모두 그릴 수 있습니다. 다만 그려지는 모든 라인은 연속적이어야 합니다. 두 개 이상의 완전히 분리된 선을 그려야 하는 경우, 라인 렌더러를 포함하는 여러 개의 게임 오브젝트를 사용해야 합니다.

라인 렌더러는 1픽셀 너비의 라인을 렌더링하지 않습니다. 라인 렌더러는 월드 단위로서 너비가 존재하는 빌보드 라인(카메라를 마주하는 폴리곤)은 렌더링하고 텍스처로 만들 수도 있습니다. 라인 렌더러는 Trail Renderer와 동일한 알고리즘을 라인을 렌더링하는 데 사용합니다.

프로퍼티

프로퍼티: 기능:
Cast Shadows Determines whether the line casts shadows, whether they should be cast from one or both sides of the line, or whether the line should only cast shadows and not otherwise be drawn. See Renderer-shadowCastingMode in the Script Ref to learn more.
Recieve Shadows 이 옵션을 활성화하는 경우 라인에 섀도우가 적용됩니다.
Motion Vectors 이 옵션을 활성화하면 선은 카메라 모션 벡터 텍스처에 렌더링된 모션벡터를 가집니다. 자세한 내용은 스크립팅 API 레퍼런스 문서에서 Renderer.motionVectors를 참조하십시오.
Materials 이 프로퍼티는 라인을 렌더링하는 데 사용된 머티리얼의 배열을 설명합니다. 라인은 배열 내 각각의 머티리얼에 대해 한 번씩 그려집니다.
Light Parameters 여기에 라이트맵 파라미터 에셋을 참조하면 라인이 전역 조명 시스템과 상호작용할 수 있게 됩니다.
Positions 이 프로퍼티는 연결할 Vector3 점 배열을 설명합니다.
        Size The number of segments in this line.
Parameters These properties describe a list of parameters for each line.
        Start Width Width at the first line position.
        End Width Width at the last line position.
        Start Color Color at the first line position. Note: This has no effect unless the attached material uses a vertex shader.
        End Color Color at the last line position. Note: This has no effect unless the attached material uses a vertex shader.
Use World Space If enabled, the points are considered as world-space coordinates, instead of being subject to the transform of the GameObject to which this component is attached.
Reflection Probes 이 옵션이 활성화된 상태에서 씬에 반사 프로브가 존재하는 경우, 해당 라인 렌더러에 대해 반사 텍스처가 지정되며 이는 빌트인 셰이더 유니폼 변수로 설정됩니다.

세부 정보

라인 렌더러를 생성하려면 다음 단계를 따르십시오.

  1. Unity 메뉴 바에서 GameObject > __Create Empty__로 이동합니다.
  2. Unity 메뉴 바에서 Component > Effects > __Line Renderer__로 이동합니다.
  3. Drag a Texture or Material onto the Line Renderer. It looks best if you use a particle Shader in the Material.

힌트

  • 라인 렌더러는 하나의 프레임에 모든 버텍스를 배치해야 하는 효과에 유용합니다.
  • The lines may seem to rotate as you move the Camera. This is intentional.
  • 라인 렌더러는 반드시 게임 오브젝트의 유일한 렌더러여야 합니다.
플레어
트레일 렌더러