OpenGL

· OpenGL
3. Spot Light - 2개의 원뿔 형태의 조명을 사용 ( 조명이 비추는 곳의 외곽은 살짝 흐려보이는 효과를 주기 위해) - inner angle과 outer angle로 원뿔의 범위 조정
· OpenGL
1. VBO.h #ifndef VBO_CLASS_H #define VBO_CLASS_H #include class VBO { public: // Reference ID of the Vertex Buffer Object GLuint ID; // Constructor that generates a Vertex Buffer Object and links it to vertices VBO(GLfloat* vertices, GLsizeiptr size); // Binds the VBO void Bind(); // Unbinds the VBO void Unbind(); // Deletes the VBO void Delete(); }; #endif 2. VBO.cpp #include"VBO.h" // Construc..
· OpenGL
* Shader (Sahde + r) - 음영을 만드는 주체 Graphic Pipeline 1. Vertex Shader - The Vertex Shader takes the positions of all the vertices and transforms them- 점들을 찍는다* 기존의 정점을 지우거나 새로운 정점을 추가하는 등의 작업은 할 수 없다 2. Shape Assembler - The Shape Assembler takes all the positions, and connects them according to a primitive - primitive: shape such as a triangle, or maybe a point, or a line - 주어진 primitive에 따라 점들을 ..
· OpenGL
#include #include #include int main() { glfwInit(); // GLFW 버전 명시 glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3); glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3); // OPENGL 프로필 설정 (Core 프로필) // Core 프로필: 최신 함수들만 사용 glfwWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE); // 창 이름이 "OpenGL" 인 800 x 800 GLFWwindow 객체 생성 GLFWwindow* window = glfwCreateWindow(800, 800, "OpenGL", NULL, NULL); if (w..
· OpenGL
참고: https://www.youtube.com/watch?v=XpBGwZNyUh0&list=PLPaoO-vpZnumdcb4tZc4x5Q-v7CkrQ6M-&index=2 1. CMake 설치 2. GLFW 설치 (OpenGL library) 3. Glad 설치 Language: C/C++/ git: version 3.3 / Profile: Core - https://glad.dav1d.de/ - 설정 후 우측 하단의 Generate 버튼 누르기 - glad.zip 다운로드 4. Visual Studio 커뮤니티 빈 프로젝트 생성 - 프로젝트 내에 Libraries 폴더 생성 - Libraries 폴더 내에 lib, include 폴더 생성 5. Cmake 열기 - glfw 폴더 안에 build 폴더 생..
Eu4ng
'OpenGL' 카테고리의 글 목록