News:

One Minute Game Review by The Happy Friar: https://ugetube.com/@OneMinteGameReviews
Also on Rumble: https://rumble.com/c/c-1115371

idTech 4 (aka Doom 3 tech) Discord Server! https://discord.gg/9wtCGHa

Main Menu

doom3lite.exe loading sequence

Started by bitterman, June 10, 2015, 01:38:42 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

bitterman

What is the loading sequence after launching doom3lite.exe (from GPL compiled code)?
Or what are the minimum resources (game data) needed to run the compiled file doom3lite.exe?

This works well if you copy the entire  base folder from the original version (which contains the game data).

doom3lite.exe first looks for a file default.cfg and get an error if it is not found. What's next?

UPDATE:

QuoteIn order to run the game you will need the base folder containing the Doom 3 assets.

When Doom3.exe starts up it:

    Loads the DLL in its process memory space via LoadLibrary.
    Get the address of GetGameAPI in the dll using win32's GetProcAddress.
    Call GetGameAPI.
    gameExport_t * GetGameAPI_t( gameImport_t *import );
       
At the end of the "handshake", Doom3.exe has a pointer to a idGame object and Game.dll has a pointer to a gameImport_t object containing additional references to all missing subsystems such as idFileSystem.

Gamex86's view on Doom 3 executable objects:

        typedef struct {
           
            int                         version;               // API version
            idSys *                     sys;                   // non-portable system services
            idCommon *                  common;                // common
            idCmdSystem *               cmdSystem              // console command system
            idCVarSystem *              cvarSystem;            // console variable system
            idFileSystem *              fileSystem;            // file system
            idNetworkSystem *           networkSystem;         // network system
            idRenderSystem *            renderSystem;          // render system
            idSoundSystem *             soundSystem;           // sound system
            idRenderModelManager *      renderModelManager;    // render model manager
            idUserInterfaceManager *    uiManager;             // user interface manager
            idDeclManager *             declManager;           // declaration manager
            idAASFileManager *          AASFileManager;        // AAS file manager
            idCollisionModelManager *   collisionModelManager; // collision model manager
           
        } gameImport_t;

http://fabiensanglard.net/doom3/

motorsep

Someone started working on minimal base/ project here. I don't know how far they got: https://github.com/DanielGibson/d3-base-assets

The way I did it was running stripped version and adding file by file as I got assert crashes (while running debug build in MSVC).

bitterman

Thanks for starting point, motorsep.

BielBdeLuna

take a look at https://github.com/OpenTechEngine/OpenTechBFG it has a more new asset repository

what is doom3little.exe?

bitterman

#4
Quote from: BielBdeLuna on June 10, 2015, 01:07:58 PM

what is doom3little.exe?

It's just a name of msvc project (lite version of source by simulation from d3w w/o editor, mfc and d3d sdk).

Btw is there a free utils to work with bmd5 and other new formats that have been used in BFG edition? Can I use in BFG models for original doom3?

motorsep

Quote from: bitterman on June 12, 2015, 01:11:41 PM
Btw is there a free utils to work with bmd5 and other new formats that have been used in BFG edition?

No. Engine binarizes/compresses Doom 3's content automatically. Why would you need to mess with binary files anyway ?

bitterman

#6
And all my old models, mods, textures etc will work correctly in bfg?

motorsep

Quote from: bitterman on June 12, 2015, 01:43:11 PM
And all my old models' textures etc will work correctly in bfg?

Except shaders and full screen guis (menu, pda, etc.), everything else should work. Why don't you give it a spin? :)

Note - it won't work with stock BFG. You need RBDoom3 BFG port.

bitterman

#8
This is another good news. Thanks!

Why I learned ARB?! ;)

motorsep

Quote from: bitterman on June 12, 2015, 01:51:54 PM
This is another good news. Thanks!

Why I learned ARB?! ;)

BFG uses Cg shaders, which engine then compiles into GLSL and HLSL. So yeah, ARB is dead :)

bitterman

#10
Quote from: motorsep on June 10, 2015, 09:19:04 AM
Someone started working on minimal base/ project here. I don't know how far they got: https://github.com/DanielGibson/d3-base-assets

Some problems with spawn player (info_player_start) when loading test.map.

The map is shutting down with " Error: Joint " " not found for 'bone_hips' on 'player1' ".

Asset included empty def/player.def.

But as I see in Player.cpp there is hardcoded call for "bone_hips" and few others, so it  gives an error.

IMHO minimal asset must include some definitions in player.def ("bone_hips" "Hips" etc) and relative anim/model.

But after include "bone_hips" "Hips" in player.def it's still not work. WIP.

Upd. Yes, it's work with add bone_ defs in player.def.

bitterman

#11
Could you show the structure of game gata from RBDoom3-BFG version?     
What are the differences with the original version?
   
There's (and where is) a file game.dll (gamex86.dll), idlib.lib?

I compiled the RBDoom3.exe file (with some errors) but can't get working window and watch the console output. And I don't have original assets from D3BFG.

I got working window with Doom3.gpl and my own game data but this minimal asset not work with RBDoom3 (it's crashing after run).

Can be RBDoom3 compiled with MSVC 2010 Express?

*************************

QuoteYour own Doom 3 BFG directory now should look like:
   /path/to/Doom3BFG/
    ->   RBDoom3BFG (or RBDoom3BFG.exe on Windows)
    -> avcodec-55.dll
    -> avdevice-55.dll
    -> avfilter-4.dll
    -> avformat-55.dll
    -> avutil-52.dll
    -> postproc-52.dll
    -> swresample-0.dll
    -> swscale-2.dll
    ->   base/
       ->   classicmusic/
       ->   _common.crc
       ->   (etc)

DLL's are not not necessarily? What's with .crc?