---
title: "VertexAttr: TypeShade 셰이더 API의 리플렉션 분류 인터페이스 참조 문서"
description: "VertexAttr, TypeShade API의 리플렉션 분류에 속하는 인터페이스입니다. 모듈의 @vertex 진입점에 있는 @location 입력 하나입니다. 개별 매개변수 또는 location이 지정된 구조체 필드에서 옵니다."
url: https://typeshade.dev/ko/api/vertexattr/
language: ko
---

# `VertexAttr`

인터페이스, 리플렉션 분류

모듈의 `@vertex` 진입점에 있는 `@location` 입력 하나입니다. 개별 매개변수 또는 location이 지정된 구조체 필드에서 옵니다.

`import type { VertexAttr } from 'typeshade'`

설명은 커밋 af54ddad5의 검토된 컴파일러 문서를 번역한 것입니다. 시그니처와 예제 코드는 원문을 따르며, 필요한 경우 설명에 편집상 수정이 반영됩니다.

## 구문

```ts
interface VertexAttr {
  readonly name: string;
  readonly emitted: string;
  readonly location: number;
  readonly type: string;
  readonly offset: number;
}
```

## 설명

속성은 선언 순서를 따르며, 각 `offset`은 이전 속성이 끝나는 위치입니다. 이 포맷들은 4바이트 레인을 사용하므로 속성 사이에 패딩이 필요하지 않습니다. 입력 순서를 바꾸면 오프셋이 바뀔 수 있습니다. `type`은 DSL 타입 키입니다. 이 값은 [`typeKey`](https://typeshade.dev/ko/api/typekey/)가 돌려주는 문자열이며, `StructLayout.fields[].type`이 쓰는 표기와 같습니다.

## 인스턴스 속성

**`name` 읽기 전용 `string`**

**`emitted` 읽기 전용 `string`**

생성된 텍스트에 쓰인 매개변수 이름입니다([규칙 11.10](https://typeshade.dev/ko/reference/rules/11-10/)).

**`location` 읽기 전용 `number`**

location입니다. 직접 적었거나(`location<n, T>`) 컴파일러가 정합니다([규칙 6.6](https://typeshade.dev/ko/reference/rules/6-6/), 변경 0135).

**`type` 읽기 전용 `string`**

**`offset` 읽기 전용 `number`**

## 함께 보기

- [`typeKey`](https://typeshade.dev/ko/api/typekey/)

## 소스

[`src/core/reflect/entry-types.ts`, 11행](https://github.com/typeshade/typeshade/blob/af54ddad5/src/core/reflect/entry-types.ts#L11), 커밋 af54ddad5 기준
