Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified SolarSystem12/.vs/freeglutProject3D/v14/.suo
Binary file not shown.
Binary file modified SolarSystem12/Debug/SolarSystem.exe
Binary file not shown.
Binary file modified SolarSystem12/Debug/SolarSystem.ilk
Binary file not shown.
Binary file modified SolarSystem12/Debug/SolarSystem.pdb
Binary file not shown.
Binary file modified SolarSystem12/freeglutProject3D.VC.db
Binary file not shown.
Binary file modified SolarSystem12/freeglutProject3D/Debug/Jupiter.obj
Binary file not shown.
Binary file modified SolarSystem12/freeglutProject3D/Debug/Mars.obj
Binary file not shown.
Binary file added SolarSystem12/freeglutProject3D/Debug/Naptune.obj
Binary file not shown.
Binary file added SolarSystem12/freeglutProject3D/Debug/Saturn.obj
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added SolarSystem12/freeglutProject3D/Debug/Uranus.obj
Binary file not shown.
15 changes: 1 addition & 14 deletions SolarSystem12/freeglutProject3D/Debug/freeglutProject3D.log
Original file line number Diff line number Diff line change
@@ -1,17 +1,4 @@
 Jupiter.cpp
 Naptune.cpp
c:\users\김준혁\project\solarsystem12\freeglutproject3d\actor.h : warning C4819: 현재 코드 페이지(949)에서 표시할 수 없는 문자가 파일에 들어 있습니다. 데이터가 손실되지 않게 하려면 해당 파일을 유니코드 형식으로 저장하십시오.
코드를 생성하고 있습니다...
컴파일하고 있습니다...
Mars.cpp
c:\users\김준혁\project\solarsystem12\freeglutproject3d\actor.h : warning C4819: 현재 코드 페이지(949)에서 표시할 수 없는 문자가 파일에 들어 있습니다. 데이터가 손실되지 않게 하려면 해당 파일을 유니코드 형식으로 저장하십시오.
코드를 생성하고 있습니다...
컴파일하고 있습니다...
Sun.cpp
c:\users\김준혁\project\solarsystem12\freeglutproject3d\sun.cpp : warning C4819: 현재 코드 페이지(949)에서 표시할 수 없는 문자가 파일에 들어 있습니다. 데이터가 손실되지 않게 하려면 해당 파일을 유니코드 형식으로 저장하십시오.
c:\users\김준혁\project\solarsystem12\freeglutproject3d\sun.h : warning C4819: 현재 코드 페이지(949)에서 표시할 수 없는 문자가 파일에 들어 있습니다. 데이터가 손실되지 않게 하려면 해당 파일을 유니코드 형식으로 저장하십시오.
c:\users\김준혁\project\solarsystem12\freeglutproject3d\actor.h : warning C4819: 현재 코드 페이지(949)에서 표시할 수 없는 문자가 파일에 들어 있습니다. 데이터가 손실되지 않게 하려면 해당 파일을 유니코드 형식으로 저장하십시오.
코드를 생성하고 있습니다...
건너뛰고 있습니다... (관련된 변경 내용 없음)
main1.cpp
freeglutProject3D.vcxproj -> C:\Users\김준혁\Project\SolarSystem12\Debug\SolarSystem.exe
freeglutProject3D.vcxproj -> C:\Users\김준혁\Project\SolarSystem12\Debug\SolarSystem.pdb (Full PDB)
Binary file modified SolarSystem12/freeglutProject3D/Debug/main1.obj
Binary file not shown.
Binary file modified SolarSystem12/freeglutProject3D/Debug/vc140.idb
Binary file not shown.
Binary file modified SolarSystem12/freeglutProject3D/Debug/vc140.pdb
Binary file not shown.
56 changes: 56 additions & 0 deletions SolarSystem12/freeglutProject3D/Naptune.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
#include "Naptune.h"
#include "TextureLoader.h"


Naptune::Naptune() //Naptune�� ������
: Sphere(10, 45, 45) //Sphere(��)�� �߽� ��ǥ ����

{

init();

}

Naptune::~Naptune() //Naptune�� �Ҹ���
{

Sphere::~Sphere();

}



void Naptune::init()
{

unsigned int width, height; //�ʺ�� ���� ����
unsigned char * data = loadBMPRaw("neptune.bmp", width, height, false); //"Naptune.bmp"������ �ҷ��´�

glGenTextures(1, &textureID); //OpenGL �ؽ��ĸ� �����
glBindTexture(GL_TEXTURE_2D, textureID); //����� �ؽ��� ������Ʈ. ������ �ؽ��Ĵ� �� �ؽ��ķ� �����Ѵ�.


//OpenGL�� �̹��� ������ �����Ѵ�.
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, width, height, 0, GL_BGR_EXT, GL_UNSIGNED_BYTE, data);
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);


//��ǥ ���͸�
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); //��巹��
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); //��巹��
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); //Ȯ�� ���͸�
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); //��� ���͸�
delete[] data;

}


void Naptune::draw() //ȭ�鿡 Naptune�� �׸���
{

glBindTexture(GL_TEXTURE_2D, textureID); //����� �ؽ��� ������Ʈ
gluQuadricTexture(quadric, GL_TRUE); //������ ��� �ؽ��ĵ��� �� �ؽ��ĸ� ����Ѵ�.
Sphere::draw(); //ȭ�鿡 Sphere�� �׸���

}

25 changes: 25 additions & 0 deletions SolarSystem12/freeglutProject3D/Naptune.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#ifndef NaptuneH
#define NaptuneH

#include "Sphere.h" //Sphere ������� ����


class Naptune :

public Sphere //Sphere Ŭ������ Public ��� ȣ��
{

private: // Naptune Ŭ������ Private ���
GLuint textureID; //�ؽ���ID�� ��Ÿ��
void init();


public: //Naptune Ŭ������ Public ���
Naptune(); //Naptune ��ü ������
~Naptune(); //Naptune ��ü �Ҹ���
void draw(); //ȭ�鿡 �׷��ִ� �Լ�

};


#endif
56 changes: 56 additions & 0 deletions SolarSystem12/freeglutProject3D/Saturn.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
#include "Saturn.h"
#include "TextureLoader.h"


Saturn::Saturn() //Earth�� ������
: Sphere(40, 45, 45) //Sphere(��)�� �߽� ��ǥ ����

{

init();

}

Saturn::~Saturn() //Earth�� �Ҹ���
{

Sphere::~Sphere();

}



void Saturn::init()
{

unsigned int width, height; //�ʺ�� ���� ����
unsigned char * data = loadBMPRaw("saturn.bmp", width, height, false); //"earth.bmp"������ �ҷ��´�

glGenTextures(1, &textureID); //OpenGL �ؽ��ĸ� �����
glBindTexture(GL_TEXTURE_2D, textureID); //����� �ؽ��� ������Ʈ. ������ �ؽ��Ĵ� �� �ؽ��ķ� �����Ѵ�.


//OpenGL�� �̹��� ������ �����Ѵ�.
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, width, height, 0, GL_BGR_EXT, GL_UNSIGNED_BYTE, data);
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);


//��ǥ ���͸�
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); //��巹��
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); //��巹��
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); //Ȯ�� ���͸�
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); //��� ���͸�
delete[] data;

}


void Saturn::draw() //ȭ�鿡 Earth�� �׸���
{

glBindTexture(GL_TEXTURE_2D, textureID); //����� �ؽ��� ������Ʈ
gluQuadricTexture(quadric, GL_TRUE); //������ ��� �ؽ��ĵ��� �� �ؽ��ĸ� ����Ѵ�.
Sphere::draw(); //ȭ�鿡 Sphere�� �׸���

}

25 changes: 25 additions & 0 deletions SolarSystem12/freeglutProject3D/Saturn.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#ifndef SaturnH
#define SaturnH

#include "Sphere.h" //Sphere ������� ����


class Saturn :

public Sphere //Sphere Ŭ������ Public ��� ȣ��
{

private: // Earth Ŭ������ Private ���
GLuint textureID; //�ؽ���ID�� ��Ÿ��
void init();


public: //Mars Ŭ������ Public ���
Saturn(); //Mars ��ü ������
~Saturn(); //Mars ��ü �Ҹ���
void draw(); //ȭ�鿡 �׷��ִ� �Լ�

};


#endif
54 changes: 54 additions & 0 deletions SolarSystem12/freeglutProject3D/Uranus.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#include "Uranus.h"
#include "TextureLoader.h"


Uranus::Uranus() //Uranus�� ������
: Sphere(20, 45, 45) //Sphere(��)�� �߽� ��ǥ ����

{

init();

}

Uranus::~Uranus() //Uranus�� �Ҹ���
{

Sphere::~Sphere();

}


void Uranus::init()
{

unsigned int width, height; //�ʺ�� ���� ����
unsigned char * data = loadBMPRaw("uranus.bmp", width, height, false); //"������ �ҷ��´�

glGenTextures(1, &textureID); //OpenGL �ؽ��ĸ� �����
glBindTexture(GL_TEXTURE_2D, textureID); //����� �ؽ��� ������Ʈ. ������ �ؽ��Ĵ� �� �ؽ��ķ� �����Ѵ�.


//OpenGL�� �̹��� ������ �����Ѵ�.
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, width, height, 0, GL_BGR_EXT, GL_UNSIGNED_BYTE, data);
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);


//��ǥ ���͸�
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); //��巹��
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); //��巹��
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); //Ȯ�� ���͸�
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); //��� ���͸�
delete[] data;

}


void Uranus::draw() //ȭ�鿡 Earth�� �׸���
{

glBindTexture(GL_TEXTURE_2D, textureID); //����� �ؽ��� ������Ʈ
gluQuadricTexture(quadric, GL_TRUE); //������ ��� �ؽ��ĵ��� �� �ؽ��ĸ� ����Ѵ�.
Sphere::draw(); //ȭ�鿡 Sphere�� �׸���
}

24 changes: 24 additions & 0 deletions SolarSystem12/freeglutProject3D/Uranus.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#ifndef UranusH
#define UranusH

#include "Sphere.h" //Sphere ������� ����


class Uranus :

public Sphere //Sphere Ŭ������ Public ��� ȣ��
{

private: // Uranus Ŭ������ Private ���
GLuint textureID; //�ؽ���ID�� ��Ÿ��
void init();


public: //Uranus Ŭ������ Public ���
Uranus(); //Uranus ��ü ������
~Uranus(); //Uranus ��ü �Ҹ���
void draw(); //ȭ�鿡 �׷��ִ� �Լ�

};

#endif
9 changes: 9 additions & 0 deletions SolarSystem12/freeglutProject3D/freeglutProject3D.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,14 @@
<ClCompile Include="Mars.cpp" />
<ClCompile Include="Mercury.cpp" />
<ClCompile Include="Mesh.cpp" />
<ClCompile Include="Naptune.cpp" />
<ClCompile Include="pixmap24RGB.cpp" />
<ClCompile Include="Satelite.cpp" />
<ClCompile Include="Saturn.cpp" />
<ClCompile Include="Sphere.cpp" />
<ClCompile Include="Sun.cpp" />
<ClCompile Include="TextureLoader.cpp" />
<ClCompile Include="Uranus.cpp" />
<ClCompile Include="Venus.cpp" />
</ItemGroup>
<ItemGroup>
Expand All @@ -97,19 +100,25 @@
<ClInclude Include="Mars.h" />
<ClInclude Include="Mercury.h" />
<ClInclude Include="Mesh.h" />
<ClInclude Include="Naptune.h" />
<ClInclude Include="pixmap24RGB.h" />
<ClInclude Include="Satelite.h" />
<ClInclude Include="Saturn.h" />
<ClInclude Include="Sphere.h" />
<ClInclude Include="Sun.h" />
<ClInclude Include="TextureLoader.h" />
<ClInclude Include="Uranus.h" />
<ClInclude Include="Venus.h" />
</ItemGroup>
<ItemGroup>
<Image Include="..\..\..\..\..\..\Downloads\earth.bmp" />
<Image Include="jupiter.bmp" />
<Image Include="mars.bmp" />
<Image Include="mercury.bmp" />
<Image Include="neptune.bmp" />
<Image Include="saturn.bmp" />
<Image Include="sun.bmp" />
<Image Include="uranus.bmp" />
<Image Include="venus.bmp" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
Expand Down
27 changes: 27 additions & 0 deletions SolarSystem12/freeglutProject3D/freeglutProject3D.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,15 @@
<ClCompile Include="Jupiter.cpp">
<Filter>Source Files\Objects</Filter>
</ClCompile>
<ClCompile Include="Saturn.cpp">
<Filter>Source Files\Objects</Filter>
</ClCompile>
<ClCompile Include="Uranus.cpp">
<Filter>Source Files\Objects</Filter>
</ClCompile>
<ClCompile Include="Naptune.cpp">
<Filter>Source Files\Objects</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="Actor.h">
Expand Down Expand Up @@ -128,6 +137,15 @@
<ClInclude Include="Jupiter.h">
<Filter>Header Files\Objects</Filter>
</ClInclude>
<ClInclude Include="Saturn.h">
<Filter>Header Files\Objects</Filter>
</ClInclude>
<ClInclude Include="Uranus.h">
<Filter>Header Files\Objects</Filter>
</ClInclude>
<ClInclude Include="Naptune.h">
<Filter>Header Files\Objects</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<Image Include="..\..\..\..\..\..\Downloads\earth.bmp">
Expand All @@ -148,5 +166,14 @@
<Image Include="jupiter.bmp">
<Filter>Resource Files</Filter>
</Image>
<Image Include="neptune.bmp">
<Filter>Resource Files</Filter>
</Image>
<Image Include="saturn.bmp">
<Filter>Resource Files</Filter>
</Image>
<Image Include="uranus.bmp">
<Filter>Resource Files</Filter>
</Image>
</ItemGroup>
</Project>
Loading