Revert "[Tizen] Implement partial update"
[platform/core/uifw/dali-adaptor.git] / dali / internal / graphics / gles / egl-graphics.cpp
index de42dea..406e69c 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2019 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -38,6 +38,16 @@ EglGraphics::~EglGraphics()
 {
 }
 
+void EglGraphics::SetGlesVersion( const int32_t glesVersion )
+{
+  mEglImplementation->SetGlesVersion( glesVersion );
+  mGLES->SetGlesVersion( glesVersion );
+}
+
+void EglGraphics::SetIsSurfacelessContextSupported( const bool isSupported )
+{
+  mGLES->SetIsSurfacelessContextSupported( isSupported );
+}
 
 void EglGraphics::Initialize( EnvironmentOptions* environmentOptions )
 {
@@ -56,6 +66,8 @@ void EglGraphics::Initialize( EnvironmentOptions* environmentOptions )
   mMultiSamplingLevel = environmentOptions->GetMultiSamplingLevel();
 
   mEglSync = Utils::MakeUnique< EglSyncImplementation >();
+
+  mEglContextHelper = Utils::MakeUnique< EglContextHelperImplementation >();
 }
 
 EglInterface* EglGraphics::Create()
@@ -65,6 +77,8 @@ EglInterface* EglGraphics::Create()
 
   mEglSync->Initialize( mEglImplementation.get() ); // The sync impl needs the EglDisplay
 
+  mEglContextHelper->Initialize( mEglImplementation.get() ); // The context helper impl needs the EglContext
+
   return mEglImplementation.get();
 }
 
@@ -72,7 +86,6 @@ void EglGraphics::Destroy()
 {
 }
 
-//Dali::Integration::GlAbstraction& EglGraphics::GetGlesInterface()
 GlImplementation& EglGraphics::GetGlesInterface()
 {
   return *mGLES;
@@ -103,6 +116,12 @@ EglSyncImplementation& EglGraphics::GetSyncImplementation()
   return *mEglSync;
 }
 
+EglContextHelperImplementation& EglGraphics::GetContextHelperImplementation()
+{
+  DALI_ASSERT_DEBUG( mEglContextHelper && "EglContextHelperImplementation not created" );
+  return *mEglContextHelper;
+}
+
 EglImageExtensions* EglGraphics::GetImageExtensions()
 {
   DALI_ASSERT_DEBUG( mEglImageExtensions && "EglImageExtensions not created" );