diff --git a/include/eepp/ui/cuicontrolanim.hpp b/include/eepp/ui/cuicontrolanim.hpp index f40774993..6a17242e4 100644 --- a/include/eepp/ui/cuicontrolanim.hpp +++ b/include/eepp/ui/cuicontrolanim.hpp @@ -51,7 +51,7 @@ class EE_API cUIControlAnim : public cUIDragable { void DisableFadeOut( const cTime & Time, const bool& AlphaChilds = true, const Ease::Interpolation& Type = Ease::Linear ); - cInterpolation * AngleInterpolation(); + cInterpolation * RotationInterpolation(); cInterpolation * ScaleInterpolation(); diff --git a/projects/android-project/compile.sh b/projects/android-project/compile.sh index 9840c1f28..2a498286f 100755 --- a/projects/android-project/compile.sh +++ b/projects/android-project/compile.sh @@ -1,4 +1,5 @@ #!/bin/sh +adb devices cd $(dirname "$0") export NDK_PROJECT_PATH=$(dirname "$0") ndk-build NDK_LOG=1 NDK_DEBUG=1 -j4 diff --git a/projects/linux/ee.config b/projects/linux/ee.config index b866c60b8..3fbdaf4a8 100644 --- a/projects/linux/ee.config +++ b/projects/linux/ee.config @@ -9,3 +9,5 @@ #define EE_DEBUG #define EE_LIBSNDFILE_ENABLED #define EE_MEMORY_MANAGER +#define EE_GL3_ENABLED 1 +#define EE_SHADERS_SUPPORTED diff --git a/projects/linux/ee.creator.user b/projects/linux/ee.creator.user index 4e17b678f..2b688eb9f 100644 --- a/projects/linux/ee.creator.user +++ b/projects/linux/ee.creator.user @@ -1,6 +1,6 @@ - + ProjectExplorer.Project.ActiveTarget @@ -18,7 +18,13 @@ CppGlobal - 1 + + QmlJS + + QmlJSGlobal + + + 2 System false 4 @@ -48,9 +54,9 @@ Desktop Desktop {388e5431-b31b-42b3-b9ad-9002d279d75d} - 19 + 0 0 - 11 + 0 /home/programming/eepp/make/linux @@ -598,6 +604,55 @@ debug-static-lib GenericProjectManager.GenericBuildConfiguration + + /home/programming/eepp/make/linux + + + true + --with-static-backend gmake + premake4 + %{buildDir}../../../ + Custom Process Step + + ProjectExplorer.ProcessStep + + + + false + -j4 eeiv + make + true + Make + + GenericProjectManager.GenericMakeStep + + 2 + Build + + ProjectExplorer.BuildSteps.Build + + + + true + clean + make + %{buildDir} + Custom Process Step + + ProjectExplorer.ProcessStep + + 1 + Clean + + ProjectExplorer.BuildSteps.Clean + + 2 + false + + debug-test + debug-eeiv + GenericProjectManager.GenericBuildConfiguration + /home/programming/eepp/make/linux @@ -887,7 +942,7 @@ release-es GenericProjectManager.GenericBuildConfiguration - 20 + 21 0 @@ -1094,6 +1149,54 @@ false true + + true + + false + false + false + false + true + 0.01 + 10 + true + 25 + + true + valgrind + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + + 2 + + + /home/programming/eepp/eeiv-debug + false + %{buildDir} + Run /home/programming/eepp/eeiv-debug + eeiv-debug + ProjectExplorer.CustomExecutableRunConfiguration + 3768 + true + false + false + false + true + true @@ -1478,7 +1581,7 @@ false true - 12 + 13 diff --git a/projects/linux/ee.files b/projects/linux/ee.files index 479ed3acf..39c03ce84 100644 --- a/projects/linux/ee.files +++ b/projects/linux/ee.files @@ -663,3 +663,4 @@ ../../external_projects.lua ../../src/eepp/ui/cuitextinputpassword.cpp ../../include/eepp/ui/cuitextinputpassword.hpp +../../assets/ee.ini diff --git a/src/eepp/graphics/ctextureloader.cpp b/src/eepp/graphics/ctextureloader.cpp index 09018731b..b62552d35 100644 --- a/src/eepp/graphics/ctextureloader.cpp +++ b/src/eepp/graphics/ctextureloader.cpp @@ -423,7 +423,7 @@ void cTextureLoader::LoadFromPixels() { int width = mImgWidth; int height = mImgHeight; - Uint32 flags = mMipmap ? SOIL_FLAG_MIPMAPS : 0; + Uint32 flags = mMipmap ? SOIL_FLAG_MIPMAPS | SOIL_FLAG_GL_MIPMAPS : 0; flags = ( mClampMode == CLAMP_REPEAT) ? (flags | SOIL_FLAG_TEXTURE_REPEATS) : flags; flags = ( mCompressTexture ) ? ( flags | SOIL_FLAG_COMPRESS_TO_DXT ) : flags; diff --git a/src/eepp/graphics/renderer/cgl.cpp b/src/eepp/graphics/renderer/cgl.cpp index faa833bbc..f75600d30 100644 --- a/src/eepp/graphics/renderer/cgl.cpp +++ b/src/eepp/graphics/renderer/cgl.cpp @@ -2,6 +2,7 @@ #include #include #include +#include namespace EE { namespace Graphics { @@ -151,6 +152,10 @@ void cGL::Init() { WriteExtension( EEGL_EXT_blend_func_separate , IsExtension( "GL_EXT_blend_func_separate" ) ); } + // NVIDIA added support for GL_OES_compressed_ETC1_RGB8_texture in desktop GPUs + // GLEW doesn't return the correct result + WriteExtension( EEGL_OES_compressed_ETC1_RGB8_texture , SOIL_GL_ExtensionSupported( "GL_OES_compressed_ETC1_RGB8_texture" ) ); + #ifdef EE_GLES WriteExtension( EEGL_ARB_point_parameters , 1 ); @@ -158,7 +163,6 @@ void cGL::Init() { WriteExtension( EEGL_ARB_multitexture , 1 ); WriteExtension( EEGL_IMG_texture_compression_pvrtc , IsExtension( "GL_IMG_texture_compression_pvrtc" ) ); - WriteExtension( EEGL_OES_compressed_ETC1_RGB8_texture , IsExtension( "GL_OES_compressed_ETC1_RGB8_texture" ) ); if ( !IsExtension( EEGL_EXT_texture_compression_s3tc ) ) { WriteExtension( EEGL_EXT_texture_compression_s3tc , IsExtension( "GL_OES_texture_compression_S3TC" ) ); @@ -193,13 +197,7 @@ bool cGL::IsExtension( const std::string& name ) { #ifdef EE_GLEW_AVAILABLE return 0 != glewIsSupported( name.c_str() ); #else - char *Exts = (char *)glGetString( GL_EXTENSIONS ); - - if ( NULL != Exts && strstr( Exts, name.c_str() ) ) { - return true; - } - - return false; + return 0 != SOIL_GL_ExtensionSupported( name.c_str() ); #endif } diff --git a/src/eepp/ui/cuicontrolanim.cpp b/src/eepp/ui/cuicontrolanim.cpp index f0b55d3b6..cea0866d5 100644 --- a/src/eepp/ui/cuicontrolanim.cpp +++ b/src/eepp/ui/cuicontrolanim.cpp @@ -347,7 +347,7 @@ void cUIControlAnim::UpdateQuad() { }; } -cInterpolation * cUIControlAnim::AngleInterpolation() { +cInterpolation * cUIControlAnim::RotationInterpolation() { if ( NULL == mAngleAnim ) mAngleAnim = eeNew( cInterpolation, () ); diff --git a/src/eepp/window/backend/SDL2/cwindowsdl2.cpp b/src/eepp/window/backend/SDL2/cwindowsdl2.cpp index 48983c6fa..56548f217 100644 --- a/src/eepp/window/backend/SDL2/cwindowsdl2.cpp +++ b/src/eepp/window/backend/SDL2/cwindowsdl2.cpp @@ -96,6 +96,10 @@ cWindowSDL::~cWindowSDL() { SDL_GL_DeleteContext( mGLContextThread ); } + if ( NULL != mSDLWindow ) { + SDL_DestroyWindow( mSDLWindow ); + } + #ifdef EE_USE_WMINFO eeSAFE_DELETE( mWMinfo ); #endif @@ -204,7 +208,7 @@ bool cWindowSDL::Create( WindowSettings Settings, ContextSettings Context ) { } #else /** @todo Add OpenGL Core Profile support? */ - /**if ( GLv_3 == Context.Version ) { + /*if ( GLv_3 == Context.Version || GLv_ES2 == Context.Version ) { SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_CORE); SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 3); SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 2); diff --git a/src/examples/sprites/sprites.cpp b/src/examples/sprites/sprites.cpp index 9c809db79..01eec76a9 100644 --- a/src/examples/sprites/sprites.cpp +++ b/src/examples/sprites/sprites.cpp @@ -11,13 +11,13 @@ void spriteCallback( Uint32 Event, cSprite * Sprite, void * UserData ) { Sprite->FireEvent( USER_SPRITE_EVENT ); } else if ( Event == USER_SPRITE_EVENT ) { // Create an interpolation to change the angle of the sprite - cInterpolation * AngleInterpolation = reinterpret_cast( UserData ); - AngleInterpolation->ClearWaypoints(); - AngleInterpolation->AddWaypoint( Sprite->Angle() ); - AngleInterpolation->AddWaypoint( Sprite->Angle() + 45.f ); - AngleInterpolation->SetTotalTime( Milliseconds( 500 ) ); - AngleInterpolation->Type( Ease::BounceOut ); // Set the easing effect used for the interpolation - AngleInterpolation->Start(); + cInterpolation * RotationInterpolation = reinterpret_cast( UserData ); + RotationInterpolation->ClearWaypoints(); + RotationInterpolation->AddWaypoint( Sprite->Angle() ); + RotationInterpolation->AddWaypoint( Sprite->Angle() + 45.f ); + RotationInterpolation->SetTotalTime( Milliseconds( 500 ) ); + RotationInterpolation->Type( Ease::BounceOut ); // Set the easing effect used for the interpolation + RotationInterpolation->Start(); // Scale the sprite if ( Sprite->Scale() < 3 ) { diff --git a/src/test/eetest.cpp b/src/test/eetest.cpp index cfe436c69..299292299 100644 --- a/src/test/eetest.cpp +++ b/src/test/eetest.cpp @@ -289,7 +289,7 @@ void cEETest::CreateUI() { Child->Visible( true ); Child->Enabled( true ); Child->StartRotation( 0.f, 360.f, Milliseconds( 5000.f ) ); - Child->AngleInterpolation()->Loop( true ); + Child->RotationInterpolation()->Loop( true ); Params.Background.Colors( eeColorA( 0xFFFF0077 ), eeColorA( 0xCCCC0077 ), eeColorA( 0xCCCC0077 ), eeColorA( 0xFFFF0077 ) ); Params.Parent( Child ); @@ -299,7 +299,7 @@ void cEETest::CreateUI() { Child2->Visible( true ); Child2->Enabled( true ); Child2->StartRotation( 0.f, 360.f, Milliseconds( 5000.f ) ); - Child2->AngleInterpolation()->Loop( true ); + Child2->RotationInterpolation()->Loop( true ); mTheme->CreateSprite( eeNew( cSprite, ( "gn" ) ), C, eeSize(), eeVector2i( 160, 100 ) ); @@ -834,7 +834,7 @@ void cEETest::LoadTextures() { TNP.resize(12); for ( i = 0; i <= 6; i++ ) { - TN[i] = TF->Load( MyPath + "sprites/" + String::ToStr(i+1) + ".png", false, ( (i+1) == 4 ) ? CLAMP_REPEAT : CLAMP_TO_EDGE ); + TN[i] = TF->Load( MyPath + "sprites/" + String::ToStr(i+1) + ".png", (i+1) == 7 ? true : false, ( (i+1) == 4 ) ? CLAMP_REPEAT : CLAMP_TO_EDGE ); TNP[i] = TF->GetTexture( TN[i] ); }