Fury3d is a cross-platform rendering engine written in c++11 and modern opengl.
Works on windows && osx operating systems currentlly.
Please note, this is just a simple project for study purpose.
Features:
-
Use modern opengl.
-
C++11 smart pointers made memory management easier.
-
Support fbx model format, you can load static models and lights directlly.
-
Easy rendering pipeline management through json serialization functionality.
-
Build-in light-pre pass rendering pipeling.
Plans:
-
Add shadow maps.
-
Add skeleton animation support.
Tested compilers:
-
MSVC 2013 Community
-
Apple LLVM version 7.0.2 (clang-700.1.81)
Because fbxsdk only offers MSVC builds on windows, so you must use MSVC to build the library.
Should work with any graphic card that supports opengl 3.3 +
You can setup custom rendering pipeline using json file:
{
"textures": [
{
"name": "gbuffer_diffuse",
"format": "rgba8",
"filter": "linear",
"wrap": "repeat",
"width": 1280,
"height": 720,
"mipmap": false
},
],
"shaders": [
{
"name": "dirlight_shader",
"type": "dir_light",
"path": "Resource/Shader/SunLight.glsl"
},
],
"passes": [
{
"name": "pass_gbuffer",
"camera": "camNode",
"shaders": [
"gbuffer_shader",
"gbuffer_notexture_shader"
],
"input": [],
"output": [
"depth_buffer",
"gbuffer_normal",
"gbuffer_depth",
"gbuffer_diffuse"
],
"index": 0,
"blendMode": "replace",
"compareMode": "less",
"cullMode": "back",
"drawMode": "renderable"
},
]
}
A simple demo should look like this:
// load scene
SceneNode::Ptr m_RootNode = SceneNode::Create("Root");
// Use FileUtil::GetAbsPath to get absolute file path on osx.
FbxUtil::Instance()->LoadScene(FileUtil::Instance()->GetAbsPath("Path to fbx"), m_RootNode);
// setup octree
OcTree::Ptr m_OcTree = OcTree::Create(Vector4(-10000, -10000, -10000, 1), Vector4(10000, 10000, 10000, 1), 2);
m_OcTree->AddSceneNodeRecursively(m_RootNode);
// Load pipeline
PrelightPipeline::Ptr m_Pipeline = PrelightPipeline::Create("pipeline");
FileUtil::Instance()->LoadFromFile(m_Pipeline, FileUtil::Instance()->GetAbsPath("Path To Pipeline.json"));
// draw scene
m_Pipeline->Execute(m_OcTree);
-
FbxSdk - for loading fbx model
-
Rapidjson - for loading pipeline setups
-
Plog - for logging
-
Stbimage - for image loading
-
Sfml - for example program
-
ASSIMP - for mesh optimization
-
Ogre3d - for octree implimentation
If you use sublimetext, you can try my GLSLCompiler plugin to debug glsl code :D