mCore = Dali::Integration::Core::New( mRenderController,
mPlatformAbstraction,
+ mGraphics,
mGlAbstraction,
mGlSyncAbstraction,
mGestureManager,
#include "test-render-controller.h"
#include <dali/public-api/common/dali-common.h>
#include <dali/integration-api/resource-policies.h>
+#include <dali/integration-api/graphics/graphics.h>
namespace Dali
{
void DoUpdate( unsigned int intervalMilliseconds, const char* location=NULL );
protected:
- TestPlatformAbstraction mPlatformAbstraction;
- TestRenderController mRenderController;
- TestGlAbstraction mGlAbstraction;
- TestGlSyncAbstraction mGlSyncAbstraction;
- TestGestureManager mGestureManager;
+ TestPlatformAbstraction mPlatformAbstraction;
+ Integration::Graphics::Graphics mGraphics;
+ TestRenderController mRenderController;
+ TestGlAbstraction mGlAbstraction;
+ TestGlSyncAbstraction mGlSyncAbstraction;
+ TestGestureManager mGestureManager;
Integration::UpdateStatus mStatus;
Integration::RenderStatus mRenderStatus;
$(DALI_CFLAGS)
-DALI_CORE_LA_LDFLAGS = $(DALI_LDFLAGS)
+DALI_CORE_LA_LDFLAGS = $(DALI_LDFLAGS) -Wl,--whole-archive,graphics/libdali-graphics.a,--no-whole-archive
DALI_CORE_LA_LIBADD = $(DALI_LDFLAGS) \
$(VULKAN_LIBS) \
platformabstractiondir = $(includedir)/dali/integration-api
platformabstractioneventsdir = $(includedir)/dali/integration-api/events
platformabstractiongraphicsdir = $(includedir)/dali/integration-api/graphics
+platformabstractiongraphicsvulkandir = $(includedir)/dali/integration-api/graphics/vulkan
platformabstraction_HEADERS = $(platform_abstraction_header_files)
platformabstractionevents_HEADERS = $(platform_abstraction_events_header_files)
platformabstractiongraphics_HEADERS = $(graphics_integration_header_files)
+platformabstractiongraphicsvulkan_HEADERS = $(graphics_vulkan_integration_header_files)
#devel api (used by adaptor / toolkit
develapidir = $(devincludepath)/dali/devel-api
linker_test_CXXFLAGS = \
$(cxx_flags) \
-I../../../automated-tests/src/dali/dali-test-suite-utils \
- $(dali_core_includes)
+ $(dali_core_includes) \
+ $(VULKAN_CFLAGS)
if ENABLE_CXX03_ABI
linker_test_DEPENDENCIES = libdali-core.la
linker_test_LDADD = \
- libdali-core.la
+ libdali-core.la \
+ $(VULKAN_LIBS)
if ENABLE_RENAME_SO
#rename
linker_test_DEPENDENCIES = libdali-core-cxx11.la
linker_test_LDADD = \
- libdali-core-cxx11.la
+ libdali-core-cxx11.la \
+ $(VULKAN_LIBS)
if ENABLE_RENAME_SO
#rename
#define VK_USE_PLATFORM_XCB_KHR
#endif
-#include <dali/graphics/vulkan/vulkan-hpp-wrapper.h>
+#include <dali/integration-api/graphics/vulkan/vulkan-hpp-wrapper.h>
#include <dali/integration-api/graphics/vulkan/vk-surface-factory.h>
#include <dali/integration-api/graphics/graphics.h>
#include <unordered_map>
#include <memory>
-#include <dali/graphics/vulkan/vulkan-hpp-wrapper.h>
+#include <dali/integration-api/graphics/vulkan/vulkan-hpp-wrapper.h>
namespace Dali
{
#include <dali/public-api/common/dali-common.h>
#include <dali/integration-api/events/event.h>
#include <dali/integration-api/gl-sync-abstraction.h>
+#include <dali/integration-api/graphics/graphics.h>
#include <dali/internal/common/core-impl.h>
namespace Dali
Core* Core::New( RenderController& renderController,
PlatformAbstraction& platformAbstraction,
+ Graphics::Graphics& graphics,
GlAbstraction& glAbstraction,
GlSyncAbstraction& glSyncAbstraction,
GestureManager& gestureManager,
Core* instance = new Core;
instance->mImpl = new Internal::Core( renderController,
platformAbstraction,
+ graphics,
glAbstraction,
glSyncAbstraction,
gestureManager,
namespace Integration
{
+namespace Graphics
+{
+class Graphics;
+}
class Core;
class GestureManager;
struct Event;
struct TouchData;
-
/**
* The reasons why further updates are required.
*/
*/
static Core* New( RenderController& renderController,
PlatformAbstraction& platformAbstraction,
+ Graphics::Graphics& graphics,
GlAbstraction& glAbstraction,
GlSyncAbstraction& glSyncAbstraction,
GestureManager& gestureManager,
$(platform_abstraction_src_dir)/system-overlay.h \
$(platform_abstraction_src_dir)/lockless-buffer.h
-graphics_integration_header_files = \
- $(platform_abstraction_src_dir)/graphics/graphics.h \
- $(platform_abstraction_src_dir)/graphics/surface-factory.h \
- $(platform_abstraction_src_dir)/graphics/vulkan/vk-surface-factory.h
-
platform_abstraction_events_header_files = \
$(platform_abstraction_src_dir)/events/event.h \
$(platform_abstraction_src_dir)/events/gesture-event.h \
$(platform_abstraction_src_dir)/events/tap-gesture-event.h \
$(platform_abstraction_src_dir)/events/touch-event-combiner.h \
$(platform_abstraction_src_dir)/events/touch-event-integ.h
+
+graphics_integration_src_files = \
+ $(platform_abstraction_src_dir)/graphics/graphics.cpp
+
+graphics_integration_header_files = \
+ $(platform_abstraction_src_dir)/graphics/graphics.h \
+ $(platform_abstraction_src_dir)/graphics/surface-factory.h
+
+graphics_vulkan_integration_header_files = \
+ $(platform_abstraction_src_dir)/graphics/vulkan/vk-surface-factory.h \
+ $(platform_abstraction_src_dir)/graphics/vulkan/vulkan-hpp-wrapper.h
+
graphics_integration_src_files = \
$(graphics_integration_dir)/graphics.cpp
-
-graphics_integration_header_files = \
- $(graphics_integration_dir)/graphics.h \
- $(graphics_integration_dir)/surface-factory.h \
- $(graphics_integration_dir)/vulkan/vk-surface-factory.h
#include <dali/graphics/vulkan/vulkan-surface.h>
#include <dali/integration-api/graphics/graphics.h>
-#include <dali/integration-api/graphics/surface-factory.h>
-
namespace Dali
{
mGraphicsImpl = std::move(impl);
}
-Graphics::~Graphics() = default;
+Graphics::~Graphics()
+{
+
+}
Dali::Graphics::FBID Graphics::Create(
std::unique_ptr<Dali::Integration::Graphics::SurfaceFactory> surfaceFactory)
/**
* fixme: dummy function to make sure the static library won't be discarded entirely during linking
*/
-void IncludeThisLibrary();
+EXPORT_API void IncludeThisLibrary();
} // Namespace Graphics
} // Namespace Integration
*/
// EXTERNAL INCLUDES
-#include <dali/graphics/vulkan/vulkan-hpp-wrapper.h>
+#include <dali/integration-api/graphics/vulkan/vulkan-hpp-wrapper.h>
// INTERNAL INCLUDES
#include <dali/integration-api/graphics/surface-factory.h>
--- /dev/null
+#ifndef DALI_GRAPHICS_VULKAN_HPP_WRAPPER_H
+#define DALI_GRAPHICS_VULKAN_HPP_WRAPPER_H
+
+/*
+ * Copyright (c) 2017 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// Vulkan without exceptions
+#ifndef VULKAN_HPP_NO_EXCEPTIONS
+#define VULKAN_HPP_NO_EXCEPTIONS
+#endif
+
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wfloat-equal"
+#pragma GCC diagnostic ignored "-Wswitch-enum"
+#include <vulkan/vulkan.hpp>
+#pragma GCC diagnostic pop
+
+#endif // DALI_GRAPHICS_VULKAN_HPP_WRAPPER_H
// CLASS HEADER
#include <dali/internal/common/core-impl.h>
+#include <dali/integration-api/graphics/graphics.h>
// INTERNAL INCLUDES
#include <dali/integration-api/system-overlay.h>
#include <dali/integration-api/gl-sync-abstraction.h>
#include <dali/integration-api/platform-abstraction.h>
#include <dali/integration-api/render-controller.h>
+#include <dali/integration-api/graphics/graphics.h>
#include <dali/internal/event/actors/actor-impl.h>
#include <dali/internal/event/animation/animation-playlist.h>
namespace Dali
{
-
namespace Internal
{
using Integration::Event;
using Integration::UpdateStatus;
using Integration::RenderStatus;
+using Integration::Graphics::Graphics;
+
Core::Core( RenderController& renderController,
PlatformAbstraction& platform,
+ Graphics& graphics,
GlAbstraction& glAbstraction,
GlSyncAbstraction& glSyncAbstraction,
GestureManager& gestureManager,
bool renderToFboEnabled )
: mRenderController( renderController ),
mPlatform(platform),
- mProcessingEvent(false)
+ mProcessingEvent(false),
+ mGraphics(graphics)
{
+ // fixme: for now to ensure libgraphics.a won't be removed during linking due to being
+ Integration::Graphics::IncludeThisLibrary();
+
// Create the thread local storage
CreateThreadLocalStorage();
namespace Integration
{
+namespace Graphics
+{
+class Graphics;
+}
class RenderController;
class PlatformAbstraction;
class GestureManager;
*/
Core( Integration::RenderController& renderController,
Integration::PlatformAbstraction& platform,
+ Integration::Graphics::Graphics& graphics,
Integration::GlAbstraction& glAbstraction,
Integration::GlSyncAbstraction& glSyncAbstraction,
Integration::GestureManager& gestureManager,
OwnerPointer<GestureEventProcessor> mGestureEventProcessor; ///< The gesture event processor
OwnerPointer<EventProcessor> mEventProcessor; ///< The event processor
+ Integration::Graphics::Graphics& mGraphics; ///< Graphics object
+
friend class ThreadLocalStorage;
};