Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Diego Pérez Peña
/
PAG_p1
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
e1ffe576
authored
Sep 26, 2025
by
Diego Pérez Peña
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Ejercicio 2 completado
parent
3973828b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
ShaderException.cpp
main.cpp
ShaderException.cpp
View file @
e1ffe576
...
@@ -57,7 +57,7 @@ std::string ShaderException::getLog() {
...
@@ -57,7 +57,7 @@ std::string ShaderException::getLog() {
aux
.
append
(
":
\n
"
).
append
(
log
).
append
(
"
\n
"
);
aux
.
append
(
":
\n
"
).
append
(
log
).
append
(
"
\n
"
);
return
log
;
return
aux
;
}
}
/**
/**
...
...
main.cpp
View file @
e1ffe576
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
#include <GLFW/glfw3.h>
#include <GLFW/glfw3.h>
#include "GUI.h"
#include "GUI.h"
#include "Renderer.h"
#include "Renderer.h"
#include "ShaderException.h"
// - Esta función callback será llamada cuando GLFW produzca algún error
// - Esta función callback será llamada cuando GLFW produzca algún error
void
error_callback
(
int
errno
,
const
char
*
desc
)
{
void
error_callback
(
int
errno
,
const
char
*
desc
)
{
...
@@ -120,7 +121,12 @@ int main() {
...
@@ -120,7 +121,12 @@ int main() {
PAG
::
GUI
::
getInstancia
().
registrarMensaje
(
std
::
string
((
const
char
*
)
glGetString
(
GL_VERSION
)));
PAG
::
GUI
::
getInstancia
().
registrarMensaje
(
std
::
string
((
const
char
*
)
glGetString
(
GL_VERSION
)));
PAG
::
GUI
::
getInstancia
().
registrarMensaje
(
std
::
string
((
const
char
*
)
glGetString
(
GL_SHADING_LANGUAGE_VERSION
)));
PAG
::
GUI
::
getInstancia
().
registrarMensaje
(
std
::
string
((
const
char
*
)
glGetString
(
GL_SHADING_LANGUAGE_VERSION
)));
PAG
::
Renderer
::
getInstancia
().
creaShaderProgram
();
try
{
PAG
::
Renderer
::
getInstancia
().
creaShaderProgram
();
}
catch
(
ShaderException
e
)
{
PAG
::
GUI
::
getInstancia
().
registrarMensaje
(
e
.
getLog
());
}
PAG
::
Renderer
::
getInstancia
().
creaModelo
();
PAG
::
Renderer
::
getInstancia
().
creaModelo
();
// - Ciclo de eventos de la aplicación. La condición de parada es que la
// - Ciclo de eventos de la aplicación. La condición de parada es que la
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment