View Issue Details

IDProjectCategoryView StatusLast Update
0004123The Dark ModDesign/Codingpublic24.06.2015 19:36
Reporteruser81Assigned ToSteveL  
PrioritynormalSeveritynormalReproducibilityalways
Status resolvedResolutionfixed 
PlatformWin32OSWindowsOS Version7 sp1
Product VersionTDM 2.03 
Target VersionTDM 2.04Fixed in VersionTDM 2.04 
Summary0004123: Unbind vsync from Dmap:
DescriptionIf you have Vsync on (for playing peruposes) it really slows down DMAP.

For 2.04 could we have this unbound please..?
TagsNo tags attached.

Activities

user81

25.04.2015 08:50

  ~0007488

Thanks for have a look at this mister.
SteveL

SteveL

19.05.2015 18:30

reporter   ~0007520

Working on this from time to time. Nearly done.

Dmap uses the standard common->Printf interface.

It has 2 levels of verbosity: the current default, which is very verbose. And an even more verbose alternative, activated by the "v" option. That option sets a flag in the dmapGlobals struct: dmapGlobals.verbose = true;

I've changed it so that dmapGlobals.verbose isn't a boolean on/off, it instead holds a value from a new enum, so we can have more than 2 levels on offer:

// Added in 0004123: "Unbind VSync from DMAP".
// Allow more concise dmap to speed it up.
typedef enum {
    VL_CONCISE = 0, // Suppress most console output, the new default
    VL_ORIGDEFAULT, // The default mode pre-TDM 2.04
    VL_VERBOSE // The original extra-verbose mode
} verbosityLevel_t;

And I've added a new function to dmap.h, that dmap will use to send its console output:

void PrintIfVerbosityAtLeast( verbosityLevel_t vl, const char* fmt, ... );

That function filters the output according to verbosity level. I've set most of the current dmap output to VL_ORIGDEFAULT. Some interesting header output plus a header for each entity processed will still be printed at the new default VL_CONCISE level.

I still need to dmap a few maps picking out messages that I missed (dmap code is widespread). We don't use the dmap code outside of dmap itself, but in case we ever want to it'll still default to VL_CONCISE. dmapGlobals.verbose is a static variable so will get initialized to 0 (i.e. VL_CONCISE) even if dmap itself hasn't been called or initialized.

I need to downgrade some warnings to mere messages, e.g. "backwards triangle in input!" -- which is normal dmap operation, and not a real warning situation. All remaining warnings will not be filtered.
SteveL

SteveL

19.05.2015 22:14

reporter   ~0007522

I'll also try to fix it so the console stays open, so the mapper can see the CM and AAS compilation steps. I'll need to add an "Open" command for the console, because the CM compilation needs to close it.
SteveL

SteveL

19.05.2015 22:48

reporter   ~0007523

Last edited: 19.05.2015 22:48

I'll keep this open a few days pending feedback.

Committed at rev 6500

/trunk/framework/Console.cpp
/trunk/framework/Console.h
/trunk/tools/compilers/dmap/dmap.cpp
/trunk/tools/compilers/dmap/dmap.h
/trunk/tools/compilers/dmap/facebsp.cpp
/trunk/tools/compilers/dmap/map.cpp
/trunk/tools/compilers/dmap/optimize.cpp
/trunk/tools/compilers/dmap/output.cpp
/trunk/tools/compilers/dmap/portals.cpp
/trunk/tools/compilers/dmap/shadowopt3.cpp
/trunk/tools/compilers/dmap/tritjunction.cpp
/trunk/tools/compilers/dmap/ubrush.cpp
/trunk/tools/compilers/dmap/usurface.cpp

SteveL

SteveL

24.06.2015 19:35

reporter   ~0007594

I'm marking this resolved despite suggestions in the forum for better and more meaningful output. Most of the junk still being spat out comes from different parts of the code that are not exclusive to DMAP and won't respond to the same method of controlling it. The issue itself is fixed: dmap is no longer affected by vsync, and as a bonus it's faster with or without vsync. If we want to improve it more later, we can.

Issue History

Date Modified Username Field Change
18.03.2015 15:55 user81 New Issue
18.03.2015 23:22 SteveL Assigned To => SteveL
18.03.2015 23:22 SteveL Status new => assigned
25.04.2015 00:39 SteveL Target Version => TDM 2.04
25.04.2015 08:50 user81 Note Added: 0007488
19.05.2015 18:30 SteveL Note Added: 0007520
19.05.2015 22:14 SteveL Note Added: 0007522
19.05.2015 22:48 SteveL Note Added: 0007523
19.05.2015 22:48 SteveL Note Edited: 0007523
24.06.2015 19:35 SteveL Note Added: 0007594
24.06.2015 19:36 SteveL Status assigned => resolved
24.06.2015 19:36 SteveL Fixed in Version => TDM 2.04
24.06.2015 19:36 SteveL Resolution open => fixed