Another Cross-Platform and multi-API Graphics Engine
Branch: master
Clone or download
Latest commit 1f8722f Jun 20, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
CMake Removed Tracked Pool Jun 16, 2018
Code FrameDebugger; Basic Camera Jun 20, 2018
Dependencies Replaced MetaCPP with custom reflection; added Mono Jun 4, 2018
Resources OEObject, Property System, Reflection using MetaCPP Dec 17, 2017
Tools/Build Changed default build type to Release; Updated appveyor.yaml Jun 5, 2018
.gitignore AppVeyor Linux build Jun 4, 2018
.gitmodules Replaced MetaCPP with custom reflection; added Mono Jun 4, 2018
.travis.yml Disable Emscripten on Travis Jun 5, 2018
CMakeLists.txt
LICENSE Initial commit Aug 1, 2017
README.md Added GL libraries to appveyor.yml Jun 5, 2018
appveyor.yml Disable Emscripten on Travis Jun 5, 2018

README.md

Build Status Build Status

OrbitEngine

OrbitEngine is a Cross-Platform and multi-API Graphics Engine. The main objective is that you can use the Engine in different ways and different platforms and it just works.

These ways are:

  • API specific classes like GLShader, D3DBuffer, GLTexture, D3DMesh.
  • API agnostic interfaces like Buffer, Mesh, Texture that will instantiate the corresponding one depending on the active context.
  • Renderers like BatchRenderer2D, PathRenderer2D, DeferredRenderer, ForwardRenderer.
  • Engine high-level stuff like Scene, SceneObject.

The current supported APIs are:

  • OpenGL & OpenGLES
  • Direct3D11

And we have plans to implement Vulkan and maybe Direct3D12.

The current supported platforms are:

  • Android
  • Emscripten
  • Linux
  • Windows

Documentation

Currently we have none. This is something that take some time, but you can see some samples on the samples repositry.

Dependencies

Currently, OrbitEngine is making use of this libraries:

  • FreeType, an open source library to render fonts
  • FreeImage, an open source library to manage popular graphics images formats
  • XShaderCompiler, an open source library to cross compiler shaders
  • Assimp, an open source library to import and export 3d model formats

All are included as submodules.

Building

OrbitEngine relies on the CMake build system and requires a CXX11 compiler.

Don't forget to update the submodules or clone the repositry with --recursive.

Windows

You can just run cmake and then compile it with Visual Studio.

Web (Emscripten)

On Windows, you must to have installed the Emscripten SDK and the Ninja build system.

Then, you have to run cmake with the Emscripten toolchain and the generator Ninja. For example:

cmake -GNinja -DCMAKE_TOOLCHAIN_FILE="%EMSCRIPTEN_SDK%\cmake\Modules\Platform\Emscripten.cmake"

After that, you can run ninja on the output directory.

Android

To build for Android on Windows, you must have the Android NDK 25.2.5. The newer versions of the NDK deprecated the way we create the APK files. (This is something to refactor)

In you Application CMakeLists you should call the procedure android_create_apk to generate the APK file:

if(ANDROID)	
	# Make sure that the Android entry point isnt getting stripped, find a better solution
	set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -u ANativeActivity_onCreate")

	include(${OrbitEngine_SOURCE_DIR}/CMake/Android/APK.cmake)
	android_create_apk(Sandbox "${CMAKE_BINARY_DIR}/APK" "libApplication.so" "")
endif()

Don't forget to link it as a shared library!

Now you run CMake with the Android toolchain. For example:

cmake -GNinja -DCMAKE_TOOLCHAIN_FILE="%ANDROID_NDK%\build\cmake\android.toolchain.cmake" -DANDROID_ABI=armeabi-v7a -DANDROID_PLATFORM=android-21

The entry point is handled by the Engine, you should use the common main. This allows the code only be written once between platforms.

Linux

You can use CMake with Make.

Don't forget to download these packages:

# X11
sudo apt-get install libx11-dev
# GL
sudo apt-get install freeglut3-dev
# GLES1 & GLES2 & EGL
sudo apt-get install libgles1-mesa libgles2-mesa-dev

License

See LICENSE.