우선 OpenGL 개발을 위한 유명한 오픈소스 라이브러리인 GLFW와 GLES를 연동한다.
1. GLFW 설치
https://www.glfw.org/download.html
Download
GLFW source code and binary distribution download links.
www.glfw.org
위 사이트에서 원하는 버전의 Windows pre-compiled binaries를 다운로드한다.
나는 Visual studio에서 x86으로 컴파일을 할 것이기 때문에 32-bit Windows binaries를 다운로드했다.
2. GLES 설치
GLEW: The OpenGL Extension Wrangler Library
The OpenGL Extension Wrangler Library The OpenGL Extension Wrangler Library (GLEW) is a cross-platform open-source C/C++ extension loading library. GLEW provides efficient run-time mechanisms for determining which OpenGL extensions are supported on the tar
glew.sourceforge.net
위 사이트에서 Windows 32-bit and 64-bit binary를 다운로드한다.
3. Visual Studio 세팅
정적 라이브러리를 프로젝트에서 사용할 수 있게 연동해준다.
- <프로젝트 세팅 → C/C++ → 일반 → 추가포함 디렉터리>에 include(헤더파일) 경로를 추가해준다.
- <프로젝트 세팅 → 링커 → 일반 → 추가 라이브러리 디렉터리>에 lib파일 경로를 추가해준다.
- <프로젝트 세팅 → 링커 → 입력 → 추가 종속성>에 사용할 lib파일 이름을 추가해준다.
참고한 블로그
[C++/Modern OpenGL] 1. OpenGL 개발 환경 세팅하기
2. OpenGL 개발 환경 세팅하기 "시작이 반이다. (Well begun is half done.)" - Aristotle 라이브러리를 사용한 경험이 잦은 사람들은 어떤 라이브러리를 가져올 때, 세팅하는 것이 어렵지는 않을 것입니다.
gongdolhoon.tistory.com
'DirectX | OpenGL' 카테고리의 다른 글
[OpenGL] 기초 4. 삼각형에 vertex shader / fragment shader 적용 (0) | 2021.12.02 |
---|---|
[OpenGL] 기초 3. 삼각형 만들기 (0) | 2021.12.02 |
[OpenGL] 기초 2. GLFW로 window 띄우기 (0) | 2021.12.02 |