Giter Site home page Giter Site logo

gaijinentertainment / dagorengine Goto Github PK

View Code? Open in Web Editor NEW
2.1K 39.0 267.0 75.92 MB

Dagor Engine and Tools source code from Gaijin Games KFT

License: Other

Batchfile 0.02% Python 0.87% Vim Script 0.01% C++ 61.44% Shell 0.01% C 29.31% SourcePawn 0.18% Objective-C++ 0.29% CSS 0.01% HTML 0.08% Squirrel 0.77% CMake 0.14% Makefile 0.01% JavaScript 0.14% Roff 0.01% HLSL 0.57% Objective-C 0.16% Assembly 5.38% Go 0.62% Meson 0.01%

dagorengine's Introduction

How to Build: Environment

Requirements for building and using the Dagor Engine toolkit: Windows 10 (x64), 16 GB of RAM, 200 GB of HDD/SSD space.

Create a project folder at the root of any drive (the folder name should not contain spaces or non-Latin characters).

md X:\develop && cd X:\develop

Clone the Dagor Engine source code and samples:

git clone https://github.com/GaijinEntertainment/DagorEngine.git
cd DagorEngine

Run the make_devtools.py script. This script will download, install, and configure the build toolkit. You should provide the path to the build toolkit folder as an argument, and the script will create this folder if it doesn't exist.

python3 make_devtools.py X:\develop\devtools

If the script is not run as an administrator, installers of certain programs may request permission for installation, which you should grant. If you plan to use plugins for 3ds Max, press 'Y' when the script asks if you want to install the 3ds Max SDK. The script will also ask to add the path X:\develop\devtools to the PATH environment variable and set the GDEVTOOL variable to point to this folder.

After the script completes its work, the X:\develop\devtools folder will be configured with the following SDKs and tools:

  • FidelityFX_SC - a library for image quality enhancement
  • fmod-studio-2.xx.xx [optional] - FMOD sound library
  • LLVM-15.0.7 - C/C++ compiler and libraries (Clang)
  • nasm - assembler
  • max2024.sdk - 3ds Max 2004 SDK
  • openxr-1.0.16 - library for AR/VR
  • vc2019_16.10.3 - C/C++ compiler and libraries (MSVC)
  • win.sdk.100 - Windows 10 SDK
  • win.sdk.81 - Windows 8.1 SDK
  • ducible.exe - a tool to make builds of Portable Executables (PEs) and PDBs reproducible
  • pdbdump.exe - a tool for dumping the content of PDB files
  • jam.exe - a small build tool that can be used as a replacement for Make

Restart the command line console to make the new environment variables available.

How to Build: Prebuilt Binaries

You will need to download and extract additional binary files from the repository https://github.com/GaijinEntertainment/DagorEngine/releases into the X:\develop\DagorEngine folder:

  • samples-base.7z - contains initial assets that will be compiled into binary files that will be loaded the game
  • samples-prebuilt-game.7z - contains precompiled assets
  • tools-prebuilt.7z - contains the prebuilt engine toolkit

The directory structure should look like this:

X:\develop\DagorEngine\tools\...

X:\develop\DagorEngine\samples\skiesSample\game
                              \skiesSample\develop
                              \skiesSample\prog

X:\develop\DagorEngine\samples\testGI\game
                              \testGI\develop
                              \testGI\prog
  • prog - game source code
  • develop - initial assets
  • game - directory where assets are placed after building and game executable files are located

How to Build: Build from Source Code

To build the "testGI" sample, navigate to the X:\develop\DagorEngine\samples\testGI\prog folder and run the "jam" command. After building, the executable file will be placed in the testGI\game folder.

Run DagorEngine/build_all.cmd to build the entire project toolkit from the source code. This process may take a considerable amount of time.

Open-source roadmap

We are going to open-source more parts of our Engine and tools. These are general and broad plans for next year, can be changed.

Documentation

  • dagor render
  • how to work with dagor assets
  • dagor level editor
  • dagor reactive gui framework

Basic dagor samples

  • Binaries of basic render and game samples (terrain, clouds, water, grass; inputs and controls) with assets sources
  • Sources of basic game samples

The Pretty Games framework

Framework with samples and documentation, based on daslang and dagor. Details yet to come.

dagorengine's People

Contributors

eledrian avatar hmatthew avatar maryalichko avatar nicsavichev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dagorengine's Issues

crypto.lib lld-link error

by the way, thanks for open source the great engine

run build_all, all other is ok but

...found 10435 target(s)...
...updating 2 target(s)...
creating lib crypto.lib
@C:\Users\ADMINI~1\AppData\Local\Temp\jam: no such file or directory
lld-link: error: lib failed

FAILED to build crypto.lib [Error #1] [win64100clang15.0.7devms4exnosp]
.

...failed lib_target ../../../_output/win64100clang15.0.7devms4exnosp/3rdPartyLibs/openssl_3_x/crypto.lib ...
...skipped ../../../samples/testGI/prog/../game/testGI-win64-dev.exe for lack of ../../../_output/win64100clang15.0.7devms4exnosp/3rdPartyLibs/openssl_3_x/crypto.lib...
...failed updating 1 target(s)...
...skipped 1 target(s)...

and
change samples\skiesSample\prog\jamfile
PlatformSpec ?= clang; to
PlatformSpec ?= vc16 ;
it build samples exe but not for clang because clang crypto.lib failed link
i can't find reason , have any idea ?

How to get sources used by some of the includes?

./DagorEngine-dagor_2024_01_02\prog\gameLibs\publicInclude\dasModules\aotBallistics.h:#include <gamePhys/ballistics/projectileBallistics.h>
./DagorEngine-dagor_2024_01_02\prog\gameLibs\publicInclude\dasModules\aotBallistics.h:#include <gamePhys/ballistics/shellBallistics.h>

I can't find the 'gamePhys/ballistics' folder in the code base. Thanks, if someone can point me in the correct direction.

DumpGRP use win32 lib instead of win64

image

For some reason the ioSys/jamfile has Platform equal at win32 and then add oddle's win32 lib instead of the win64, and i cannot find where it's being set

for the time being i just cheated and added -s Platform=win64 to the jam command line in the build_dagor3_cdk_mini.cmd
image

For some reason the dumpGrp is the only that's missing

Also i think that the -s aren't supposed to be without a gap after the text
image

Failed to build CDK

Been trying to build the CDK tools but I keep getting an error
image

Am I doing something wrong or am I missing something?

Better Darg documentation

The DaRg docs only show method definitions, but can there be more examples and explanations to actually use it? The usages of DaRg in the engine source code aren't exactly beginner-friendly either and are pretty confusing.

Also, Can standalone compilation of dargox be done including their dependent libraries (as referenced in issue #29)?

Updates?

I didn't see like any updates in ~4 months. Can I ask what is going on? I'm just curious.

Blender plugin not working on 4.0?

I installed the plugin on blender(4.0) and I can see that it's been installed but I can't check it to use it for some reason. What am I doing wrong?
스크린샷(11)

Errors while Compiling Source files

When trying to compile prog\gameLibs\gamePhys\common\polares.cpp with LLVM i get this:

polares-1dcf16.obj : error LNK2019: unresolved external symbol "void __cdecl sincos(float,float &,float &)" (?sincos@@YAXMAEAM0@Z) referenced in function "class Point2 __cdecl gamephys::calc_c(struct gamephys::Polares const &,float,float,float,float)" (?calc_c@gamephys@@YA?AVPoint2@@AEBUPolares@1@MMMM@Z)
polares-1dcf16.obj : error LNK2019: unresolved external symbol "float const * const math_float_zero" (?math_float_zero@@3QBMB) referenced in function "public: class Point2 __cdecl Interpolator<class eastl::fixed_vector<struct InterpolatePoint<class Point2>,8,0,class eastl::dummy_allocator> >::interpolate(float)const " (?interpolate@?$Interpolator@V?$fixed_vector@U?$InterpolatePoint@VPoint2@@@@$07$0A@Vdummy_allocator@eastl@@@eastl@@@@QEBA?AVPoint2@@M@Z)
polares-1dcf16.obj : error LNK2019: unresolved external symbol "bool __cdecl inverse44(class TMatrix4 const &,class TMatrix4 &,float &)" (?inverse44@@YA_NAEBVTMatrix4@@AEAV1@AEAM@Z) referenced in function "void __cdecl gamephys::recalc_mach_factor(struct gamephys::PolaresProps &)" (?recalc_mach_factor@gamephys@@YAXAEAUPolaresProps@1@@Z)
polares.exe : fatal error LNK1120: 3 unresolved externals
clang-cl: error: linker command failed with exit code 1120 (use -v to see invocation)

am i using the wrong compiler/version? has anyone else been able to actually edit any of the source code?

[Question] Node visibility

After modeling in the blender, I look at it in the asset viewer, and I raise a question about Node Visibility.

I wonder how to add multiple nodes to Node visibility,
I don't think there's much information about this, so I'm asking what I should do with the blender and what code I should put in the blk file.

Evaluate using Profile-Guided Optimization (PGO)

Hi!

I am collecting all materials (benchmarks, articles, stories, showcases, etc.) about Profile-Guided Optimization (PGO) across different applications here. I am sure you will be able to find helpful information regarding PGO in different application domains.

Related to the gamedev domains, I suggest you look at the following things:

  • I did some benchmarks for Bevy with PGO. PGO-run (first) vs non-PGO (second) - Pastebin. In these results you need to interpret performance decrease as "Release version is slower than PGOed" and performance increase as "Release version is faster than PGOed". As you see, in many scenarios PGO improves performance, but in some of them performance is decreased.
  • Unreal Engine supports PGO build since 4.27 (release notes). According to the documentation, PGO allows to achieve better performance on UE too (+10% on some CPU-heavy scenarios from this page). Also, I've talked with developers in a local Telegram chat about UE. A person said that they use PGO as a default optimization with UE and their games. The PGO profiles are collected via crafted local test workloads (usually - the most difficult scenes) with Gauntlet. The performance improvement is something like 6-8%
  • Godot proposal about PGO - link
  • Unity Burst thread about PGO - link

According to the materials above, I think trying to optimize DagorEngine with PGO would be a good idea.

We need to check the PGO effects on DagorEngine, and if it works well - write a note in the DagorEngine documentation (at least in the README file, I guess?) about building with PGO. I'd appreciate your providing an easy way to build DagorEngine with PGO (e.g. via custom build options in the build scripts), and experienced users will be able to do it on their own for their own usage scenarios. Also, optimizing prebuilt binaries with PGO would be a nice thing to have (if it's possible to prepare a generic enough workload).

Seems like the main target platform is Windows so I can suggest starting looking at MSVC documentation about PGO.

Questions about Texture Loads

I'm creating a custom model and I'm posting questions about the texture.

I finished the blk coding and saw this error in the Asset Viewer.
Despite writing the tga file, these errors came up, and I'm asking you a question because I'm wondering exactly how to solve them.

For your information, I modeled it using a blender.

image

Some DDS Seems to lose the alpha channel

login_layer_t72b_1_8.zip

In this zip is the ddsx of one of the layer of the T72B Loading Screen.

For unknown reason the DDS extracted from the ddsx seems to have lost its Alpha channel, meaning that every pixel has an alpha of 0 (both using Gaijin's tool that i build yesterday, and the tool we had before)

If set the alpha of every pixel to 255 via paint.net, i can see that the image is the cannon "flash" (see screnshot), which shouldn't be transparent by any mean.
image

Looking at the hex header doesn't seem to have any issue, i has the same format as others dds that unpack without issue.

The vromfs i got the ddsx from is direct from the game, and even using Gaijin's vromfs unpacker doesn't change anything.

I would appreciate any help

Blender plugin - Equivalent to a Note Track + Keyframes from 3ds Max

Hello. (・ω・`)
This is mostly a question related to asset exportation to Dagor for War Thunder, I am creating a simple guide for asset exportation to Dagor on both 3ds Max and Blender, and I've discovered that Blender doesn't seem to have something akin to a Note Track with its own keyframes like in 3ds Max.

Without this, it is impossible to export animated assets from Blender to Dagor, only static ones. (Unless you export them to Dagor as is, and then import them to 3ds Max with the Dagor importer for animation purposes)

Do you know if such a function exist and how to use it, or if not is it possible to develop such a function? ε-(´∀`; )

Thank you! (=´∀`)人(´∀`=)
Best regards,
Avarik

ddsx2dds "Oodle read error"

i'm trying to process some DDSX using the ddsx2dds converter in the built release but i'm getting this error
image

I have the Oodle dll next to the exe and removing it gives another error
image
image
So i guess that it is loading the dll correctly but it's crashing somewhere

Even tho i love programing i never really understand how cmake worked, i tried to built the project from source but i'm missing jam, which require cmake to make

Are we perhaps gonna receive some documentations soon ?

Questions about engine development

Hello, i'm glad to see the War Thunder engine XD, it's my favorite game, but i have some doubts about the development of this engine.

  1. There is a roadmap for next features/fixes?
  2. There is a documentation/manual/guide (instead samples) ?
  3. Any community ?
  4. This engine is open to new contribuitors ?
  5. Can i use Dagor for my games?

de_dust2 is missing from testGI assets

Hello, as seen in the settings.blk file included with testGI, there is a line showing that de_dust2 is supposed to be a loadable environment, however it is missing from the levels directory.

How to create a landscape

Hi! I am currently do some experiments with Dagor Engine. I have built the binaries, and it works fine. However, I am not able to create a landscape in any possible way. When I do Create Heightmap or Import Heightmap, nothing happens. (Well, I mean, technically happens because there is a windows which asks about sizes, etc, and the console says that heightmap was created/imported), but I am not able to see the landscape in any way. even after restarting the editor, or "baking lights". nothing just appears. probably I am doing something wrong.. i guess...

Regarding the user mod

image
I don't know if I'll get the exact answer when I post a question like this here, but as I'm creating a custom model and creating a user mode, I'd like to know if there's a document on the code of this content (especially the blk code for missiles). Especially the exact way it works for rangeMax:p4 shown in the image above.

Possible light bleeding.

These two screenshots in Sponza Demo (testGI) show that light on the common edge of wall and floor has tendency to disappear when camera moves closer. Maybe that's because shadow rendering distance is low (I don't know how to change that, haven't found in ImGUI right option).
изображение
изображение
Hardware: Intel i3-4130 (2 cores 3.4 GHz), AMD R7 260X, 6 Gb RAM. Testing has been done on Windows 7.

[Question] About the Blender extension..

I have some questions about using Blender to create models for DagorEngine.

I'm interested in using the Blender extension to make models for WarThunder. The Blender extension included in the WarThunder CDK only works with older versions of Blender, and doesn't keep objects separate (all meshes are combined into 1, so it is not useful for creating aircraft). Therefore I thought I would try dag4blend in this project.

1) What version of Blender should I use?
I've tried zipping the contents of dag4blend into a file called bl_dag_exporter.zip and then in Blender, preferences->addons->install But I don't see the addon added to the list of installed add-ons. I have tried in Blender 2.49b, 2.71, 3.3.0

2) Do I need to build blk2dag to export from Blender to Dagor? The extension in the Thunder CDK depended upon blk2dag.exe so I am wondering if this is still a requirement.

  1. If the answer to 2 is yes, then do I need to build the whole DagorEngine, or can blk2dag be built by itself?

GPU Incompatibility

When i start the editor, everything seems to work. but when selecting the Skies Sample for example, im getting multiple errors. They look like this:
Screenshot 2023-11-01 155507. I have an RTX 2060, so i cant find a reason for it to give me those errors.

Working with scripts

Is there currently any way, to customize game logic. Like, I have created a project, based on testGI, but I was not able to find any examples of "scripts" in samples. Or there is no way currently to customize game's logic right now? The docs are also have not any information about it

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.