Commit Graph

38 Commits

Author SHA1 Message Date
Eric Wasylishen fbea58d679 code formatting pass 2023-06-25 18:29:48 -06:00
Jonathan caa7418375 async threading for map progress, etc. no cancelling yet 2023-06-19 15:38:16 -04:00
Eric Wasylishen 9c6f6c2589 common: change FError to throw an exception 2023-06-03 22:24:20 -06:00
Eric Wasylishen 317bf32671 common: use "bright black" for percent text color
the "blue" one was hard to read with the Windows legacy terminal color scheme
2023-05-31 22:27:32 -06:00
Eric Wasylishen e069d7b9b8 style: update settings api to follow current coding style 2023-04-16 11:55:38 -06:00
Eric Wasylishen b17633f746 cleanup: set PackConstructorInitializers: Never 2023-02-20 10:23:59 -07:00
Eric Wasylishen eda6155844 cleanup: run ./clang-format-all.sh
clang-format version 15.0.7
2023-02-18 22:59:43 -07:00
Eric Wasylishen 9ab4ea8176 Move SetConsoleMode() call to logging::preinitialize(); helper
Don't do ENABLE_VIRTUAL_TERMINAL_INPUT as it breaks arrow key history
navigation in Windows Terminal after running one of the ericw-tools exe's.
2022-11-19 10:05:14 -07:00
Eric Wasylishen 629f86625e log.cc: use fmt::group_digits to avoid locale manipulation
this is to get thousands separators, e.g. 10000 prints as 10,000

the `auto old = std::locale::global(std::locale("en_US.UTF-8"));` line was throwing
on Win8.1
2022-11-13 18:58:08 -07:00
Eric Wasylishen 2bd2515792 all: cleanup unused includes (Clion - detect not directly used) 2022-10-31 21:37:34 -06:00
Eric Wasylishen 34f32f851c common, qbsp: more functions moved from header -> source 2022-10-26 23:29:54 -06:00
Eric Wasylishen 636b376577 squash brushbsp-compilation-speedup branch
move function implementations out of headers
2022-10-21 18:00:58 -06:00
Jonathan 315ab418d2 fix warning
only enable the clock counter errors in debug
2022-10-02 16:20:27 -04:00
Jonathan 075481a36f add -nocolor for TB, etc
fix crashes on vis and light for invalid options
fix TB and others not receiving output
2022-08-31 12:58:04 -04:00
Jonathan 282c5ec69f stat printing adjustments 2022-08-21 15:01:45 -04:00
Jonathan 8b9c1bd784 fix missing includes 2022-08-12 02:42:52 -04:00
Jonathan bf162c7a86 allow explicit calling of percent_clock so it can be simplified a bit
add more timers in a few spots
by default, display percent timers but don't display elapsed for non-verbose stuff (bmodels); this is so it still shows that it's "working" instead of just showing blank for large maps, give user an idea on progress for certain stuff
merge all "side not found"s into a single line
time `FillOutside`
time `ProcessMapBrushes`
time `Brush_LoadEntity`
2022-08-12 01:30:04 -04:00
Jonathan 4bf2ab338c allowing logging::percent to handle indeterminate values
fix logging::percent getting stomped in multi-threaded operations
add new stats facility to make creating lists of single-use stats easier to manage
fix SplitBrush storing a bunch of extra stats for ChopBrushes
2022-08-11 20:33:12 -04:00
Jonathan 44eff2d7b1 throw in percent logging for MakeTreePortals
when node_t converts to leaf, destroy anything on it by re-initializing it
2022-08-09 20:33:49 -04:00
Jonathan 26a18d5cc3 add logging::header/funcheader to easily and consistently print function or "active routine" headers
add OOP percent_clock wrapper to make printing percents easier, not used yet
2022-08-01 09:35:21 -04:00
Jonathan 1d8a0c1df3 clang-format pass 2022-07-28 06:14:54 -04:00
Eric Wasylishen 64159d92f1 Merge remote-tracking branch 'github-desktop-paril/type-cleanup' into brushbsp 2022-06-10 21:32:23 -06:00
Jonathan 812797f7ed enable lighting for warp/sky in Q2
simplify bitflag definitions
change nudging light warning to make more sense
another #define -> constexpr pass
2022-06-10 06:29:14 -04:00
Jonathan 54efff2e7a don't print out % if it hasn't changed 2022-06-06 03:29:33 -04:00
Jonathan c5e864fca1 re-enable stuff
undo the shared lock stuff
2022-06-06 03:26:19 -04:00
Eric Wasylishen 6102390986 log: don't pass ANSI colors to OutputDebugStringA
since they aren't rendered in VS's Output window
2022-04-03 14:16:54 -06:00
Eric Wasylishen 24ca07188c log: use ANSI colors for strings containing "warning" or "error" 2022-04-03 14:16:22 -06:00
Eric Wasylishen c9a6ba402c log: don't pass ANSI colors to OutputDebugStringA
since they aren't rendered in VS's Output window
2022-04-03 14:15:48 -06:00
Eric Wasylishen a0fbfdbad5 log: use ANSI colors for strings containing "warning" or "error" 2022-04-03 12:56:11 -06:00
Jonathan f5cda68416 clean up percent stuff
comment out "didn't split" message
fix winding resize
merge phong loops together
2022-03-07 14:49:50 -05:00
Jonathan c81e9ace28 remove old threading code entirely
add new parallel logging stuff in common/parallel which wraps parallel_for(_each) and provides automatic percentage indicator
fix issue with light not pulling in settings
move logging stuff into its own namespace and simplify
2022-03-01 10:28:59 -05:00
Jonathan 52839d4e7f Run clang-format pass 2021-10-05 15:54:06 -04:00
Jonathan 326626f127 Remove some old stuff
Cleanup/rework of logging system. I'm not too happy about it still, but, it's at least a bit easier to follow now.
Started cleanup of file-related stuff.
2021-09-19 18:17:28 -04:00
Jonathan eb6bb81d61 use the C++ includes
stdbool not required
_vsnprintf and _snprintf are standard in MSVC since 2015, so I just use them directly now. They'll be replaced by std::fmt later anyways.
use <thread> for threading, instead of pthreads/windows.h thread directly
2021-09-14 08:46:03 -04:00
Jonathan 4e7542b111 Clang format pass
typedef -> using
include guards -> pragma once
typedef struct x { } y; -> struct y { }
some fixes to extremely old code that shouldn't be required any more
2021-09-14 02:32:26 -04:00
Eric Wasylishen cbba35a346 common: logprint: print to visual studio console 2017-10-24 19:51:29 -07:00
Eric Wasylishen cefadfa1f4 build: fix on MSVC 2013 2016-10-17 19:25:27 -07:00
Eric Wasylishen a6468984bf all: finish c++ification 2016-10-17 19:52:17 -06:00