The Harfang 3D engine
category: code [glöplog]
Dear demoscene fellows,
I would like to share with you the result of our efforts during the past years.
We are a small team (5 ppl) with various demoscene, gamedev, design and engineering backgrounds and we’re building a 3D engine : HARFANG.
The starting point was a C++ 3D engine, bound to a scripting language, helping “not-so-experts” to create interactive 3D content.
Today, the engine has reached a certain level of maturity and I think it could be of some interest to the demoscene community:
HARFANG comes in 2 parts:
Harfang 3D is licensed under an hybrid GPLv3/LGPLv3/Commercial License. The later one says, basically, that you can use the engine for free until you decide to ship a commercial product, on which we ask 3% of the gross revenue (other licensing schemes can be discussed).
Harfang 3D is available for download, in several flavors:
Harfang Studio is available for download, on Win64 only so far, but there is a prototype of a Linux version that can be made available in a near future, if needed.
AAA rendering in HARFANG 3D (the runtime)
The same scene in HARFANG Studio (the editor)
In addition to the Python wheel, one of our colleagues built a “batteries included” Python module to ease the first contact with HARFANG. It’s called Harfang High Level.
What are the engine’s features ?
The later feature is very important for us. The idea is that you should be able to download the Vanilla Python (or Anaconda), Lua or Go environnement and import Harfang as well as any other package :
Python
Lua
Go
You will find a series of code snippets in Python, Lua or Go here, some equivalent in C++ here and a series of video tutorials here.
So far, one demoscene production was made with Harfang (by yours truly, code is in Lua, avail. on github). I hope in the future we will see some more :)
To conclude this long post, here are some examples of applications implemented on HARFANG :
At this point of this long post, I will let you people take your time to absorb all this information.
Feel free to send us feedbacks, comments, etc about our little piece of software :)
I would like to share with you the result of our efforts during the past years.
We are a small team (5 ppl) with various demoscene, gamedev, design and engineering backgrounds and we’re building a 3D engine : HARFANG.
The starting point was a C++ 3D engine, bound to a scripting language, helping “not-so-experts” to create interactive 3D content.
Today, the engine has reached a certain level of maturity and I think it could be of some interest to the demoscene community:
HARFANG comes in 2 parts:
- the engine itself, called “Harfang 3D”
- the scene editor, called “Harfang Studio”
Harfang 3D is licensed under an hybrid GPLv3/LGPLv3/Commercial License. The later one says, basically, that you can use the engine for free until you decide to ship a commercial product, on which we ask 3% of the gross revenue (other licensing schemes can be discussed).
Harfang 3D is available for download, in several flavors:
- a Python wheel (.whl) for Windows (32/64) or Linux (64) here
- a Lua extension (.dll) for Windows (32/64) or Linux (64) here
- a Go module (whatever go uses as an extension) for Windows (32/64) or Linux (64) here
- the source code (mostly C++) here
- a binary “SDK” with .lib and all for those who don’t want to build the source here
Harfang Studio is available for download, on Win64 only so far, but there is a prototype of a Linux version that can be made available in a near future, if needed.
AAA rendering in HARFANG 3D (the runtime)
The same scene in HARFANG Studio (the editor)
In addition to the Python wheel, one of our colleagues built a “batteries included” Python module to ease the first contact with HARFANG. It’s called Harfang High Level.
What are the engine’s features ?
- forward rendering, classic (pbr, shadow maps) or AAA (same as “classic” with a combination of SSR & SSGI). Our rendering pipeline is built on top of BGFX, a very complete backend abstraction created by a former demomaker
- physics engine (we rely on Bullet Physics)
- scripting (the Lua VM is embedded in Harfang)
- VR API (using OpenVR, OpenXR is in progress)
- audio (we rely on OpenAL)
- the engine tries to blend as natively as possible in its target environment, be it Python, Lua or Go.
The later feature is very important for us. The idea is that you should be able to download the Vanilla Python (or Anaconda), Lua or Go environnement and import Harfang as well as any other package :
Python
Code:
import harfang as hg
Lua
Code:
hg = require(“harfang”)
Go
Code:
import (
hg "github.com/harfang3d/harfang-go/v3"
)
You will find a series of code snippets in Python, Lua or Go here, some equivalent in C++ here and a series of video tutorials here.
So far, one demoscene production was made with Harfang (by yours truly, code is in Lua, avail. on github). I hope in the future we will see some more :)
To conclude this long post, here are some examples of applications implemented on HARFANG :
- A prototype of flight simulator that works in VR (code in python) : video and source
- A robotic digital twin (less than 200 lines of Python :)) : video and source
- A prototype of HUD running live in a democar (this one is in C++): video
- … and a brief overview of what HARFANG Studio looks like in this video
At this point of this long post, I will let you people take your time to absorb all this information.
Feel free to send us feedbacks, comments, etc about our little piece of software :)
Impressive work! Kudos!
Beautiful!
This looks great!
looks incredible, thanks for sharing <3
Amazing Work!
wow, kudos!
Looks fantastic! Is there any way to run studio under Linux? Looking forward to making something with this, and Luau support would be nice =)
@ezra what Linux distro do you run, out of curiosity ? :)
mac version? By the way, it looks amazing.
@swapd0 : a chinese game developer sent me a couple of photos showing he managed to get Harfang running on his Macbook M2, unfortunately he couldn't find the time to send us a pull request :')
Apparently it's only a matter of fixing a few lines in the cmake and telling our asset compiler (assetc) to switch to metal when compiling the shaders.
Apparently it's only a matter of fixing a few lines in the cmake and telling our asset compiler (assetc) to switch to metal when compiling the shaders.
@fra I run Arch!
Quote:
mac version? By the way, it looks amazing.
For what it's worth, here's the "OS X" quick'n'dirty patch to make it work by Eastward's lead developer who kindly agreed to push his attempt on a Macbook ARM:
www.github.com/astrofra/harfang3d/tree/macos
Sooner or later we will need to get a Mac and add it to the C/I :')
@ezra: okie! 'will keep that in mind.
3.2.5 update, bringing various little things:
* OS X experimental port starting to work (but not production-proof yet)
* WASM support compat' improoved
* OpenXR support, incl. the Varjo XR headset
* Physics support improved
* the asset compiler is now bundled both with Python and Lua
https://github.com/harfang3d/harfang3d/releases/tag/v3.2.5
Enjoy!
* OS X experimental port starting to work (but not production-proof yet)
* WASM support compat' improoved
* OpenXR support, incl. the Varjo XR headset
* Physics support improved
* the asset compiler is now bundled both with Python and Lua
https://github.com/harfang3d/harfang3d/releases/tag/v3.2.5
Enjoy!
Hi folks.
Not super new, but in June we uploaded a quick update for HARFANG 3.2.6
Check here : https://github.com/harfang3d/harfang3d/releases/tag/v3.2.6
If you feel like it, give us a here: https://github.com/harfang3d/harfang3d
... and Psykon was kind enough to add the engine in his list of demoscene-ish tools :)
Not super new, but in June we uploaded a quick update for HARFANG 3.2.6
Check here : https://github.com/harfang3d/harfang3d/releases/tag/v3.2.6
If you feel like it, give us a here: https://github.com/harfang3d/harfang3d
... and Psykon was kind enough to add the engine in his list of demoscene-ish tools :)
Your team and you made an amazing work !
Congrats :)
Congrats :)