소스 검색

build: some PS4 compilation fixes.

undefined
Sam Hocevar 10 년 전
부모
커밋
e5faf45929
4개의 변경된 파일17개의 추가작업 그리고 14개의 파일을 삭제
  1. +7
    -7
      build/autotools/m4/lol-gl.m4
  2. +3
    -2
      src/lol/base/enum.h
  3. +4
    -2
      src/scene.cpp
  4. +3
    -3
      src/video.cpp

+ 7
- 7
build/autotools/m4/lol-gl.m4 파일 보기

@@ -100,12 +100,7 @@ if test "x${ac_cv_my_stop_looking_for_gl}" = "xno"; then
LIBS="$LIBS_save"])
fi

if test "${ac_cv_my_have_gl}" = "no"; then
AC_MSG_ERROR([[No OpenGL or OpenGL ES implementation found]])
fi


dnl Use Glew?
dnl Use Glew?
ac_cv_my_have_glew="no"
PKG_CHECK_MODULES(GLEW, glew,
[ac_cv_my_have_glew="yes"
@@ -130,12 +125,17 @@ if test "${ac_cv_my_have_glew}" != "no"; then
fi
AM_CONDITIONAL(USE_GLEW, test "${ac_cv_my_have_glew}" != "no")

dnl Poor man's GL feature detection if all else failed.
dnl Poor man's GL feature detection if all else failed.
save_LIBS="${LIBS}"
LIBS="${LIBS} ${GL_LIBS} ${GLES2_LIBS}"
AC_CHECK_FUNCS(glBegin)
LIBS="${save_LIBS}"

dnl Warn if we couldn't find an OpenGL-like API
if test "${ac_cv_my_have_gl}" = "no"; then
AC_MSG_WARN([[No OpenGL or OpenGL ES implementation found]])
fi

])# LOL_CHECK_OPENGL



+ 3
- 2
src/lol/base/enum.h 파일 보기

@@ -21,9 +21,10 @@ class Enum
{
public:
template<typename T>
static String EnumToString(T& parameter)
static String EnumToString(T const& parameter)
{
//Create your own
UNUSED(parameter);
// Create your own
ASSERT(0);
return String();
}


+ 4
- 2
src/scene.cpp 파일 보기

@@ -302,9 +302,11 @@ void Scene::RenderTiles() // XXX: rename to Blit()
rc.SetAlphaFunc(AlphaFunc::GreaterOrEqual, 0.01f);

#if defined USE_D3D9 || defined _XBOX
#elif !defined HAVE_GLES_2X
/* TODO */
#elif (defined USE_GLEW || defined HAVE_GL_2X) && !defined HAVE_GLES_2X
glEnable(GL_TEXTURE_2D);
#endif

if (!data->m_tile_shader)
data->m_tile_shader = Shader::Create(LOLFX_RESOURCE_NAME(tile));
if (!data->m_palette_shader)
@@ -400,7 +402,7 @@ void Scene::RenderTiles() // XXX: rename to Blit()

#if defined USE_D3D9 || defined _XBOX
/* TODO */
#elif !defined HAVE_GLES_2X
#elif (defined USE_GLEW || defined HAVE_GL_2X) && !defined HAVE_GLES_2X
glDisable(GL_TEXTURE_2D);
#endif
}


+ 3
- 3
src/video.cpp 파일 보기

@@ -65,7 +65,7 @@ void Video::SetDebugRenderMode(DebugRenderMode d)
{
#if defined USE_D3D9 || defined _XBOX
#elif defined HAVE_GLES_2X
#else
#elif defined USE_GLEW || defined HAVE_GL_2X
glEnable(GL_CULL_FACE);
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
#endif
@@ -75,7 +75,7 @@ void Video::SetDebugRenderMode(DebugRenderMode d)
{
#if defined USE_D3D9 || defined _XBOX
#elif defined HAVE_GLES_2X
#else
#elif defined USE_GLEW || defined HAVE_GL_2X
glDisable(GL_CULL_FACE);
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
#endif
@@ -105,7 +105,7 @@ void Video::Capture(uint32_t *buffer)
{
#if defined USE_D3D9 || defined _XBOX
/* TODO */
#else
#elif defined USE_GLEW || defined HAVE_GL_2X || defined HAVE_GLEX_2X
GLint v[4];
# if defined __CELLOS_LV2__
// FIXME: use psglCreateDeviceAuto && psglGetDeviceDimensions


불러오는 중...
취소
저장