Eric Wasylishen
4a360989f3
qbsp: add -worldextent option for compiling large maps, default 65536
2018-12-24 01:53:08 -07:00
Eric Wasylishen
fc72bbb935
qbsp: fix _mirrorinside on bmodels so that they have CONTENTS_SOLID
...
as expected
2018-08-28 21:23:08 -06:00
Eric Wasylishen
8164506d30
qbsp: read valve 220 with q2/q3 flags
...
Fixes #212
2018-04-12 15:07:07 -06:00
Eric Wasylishen
02e66edd5b
qbsp: make "too many edges" have a clear error message, instead of
...
an assertion failure
2018-04-05 22:18:28 -06:00
Eric Wasylishen
4491598bdb
qbsp: fix qbsp crash when worldspawn has 0 brushes
2018-03-23 14:48:20 -06:00
Eric Wasylishen
30c19ab9da
qbsp: support reading Q2/Q3 detail flag
2018-03-18 19:50:35 -06:00
Eric Wasylishen
f92b48a8cb
qbsp: experimental _noclipfaces key
2018-03-13 12:23:41 -06:00
Eric Wasylishen
c9b32214c1
qbsp: fix "_mirrorinside" on bmodels.
...
NOTE: This turns the contents of bmodels to CONTENTS_EMPTY if
"_mirrorinside" is used. This is not ideal (e.g. if used on a func_door,
bullets will go through the door but it blocks the player), but it's
usable for func_illusionary at least.
2018-03-12 21:15:31 -06:00
Eric Wasylishen
94dbd0a705
qbsp: _phong_angle_concave support
2018-01-30 01:20:38 -07:00
Eric Wasylishen
3b3d753cf4
qbsp: make -omitdetail affect all detail types
2018-01-30 01:10:25 -07:00
Eric Wasylishen
95e9fdcd21
qbsp: tidy up "repairing" warning message
2018-01-28 02:03:00 -07:00
Eric Wasylishen
84bf594892
qbsp: heal invalid texture projections
2018-01-28 01:55:09 -07:00
Eric Wasylishen
23b25a0a0e
qbsp: add failing tests for healing invalid texture projections
2018-01-28 01:54:58 -07:00
Eric Wasylishen
57510eab0e
qbsp: remove hint/skip texinfo clearing hack.
...
Fixes https://github.com/ericwa/ericw-tools/issues/196
This should be by stripping unreferenced texinfo at the end of compiling
2018-01-06 01:29:31 -07:00
Eric Wasylishen
84b493d7d2
qbsp: update manual
2017-10-25 14:07:25 -07:00
Eric Wasylishen
ddf29d4104
qbsp: fix not being able to see between leafs within a func_illusionary_visblocker
2017-10-25 12:04:52 -07:00
Eric Wasylishen
2ea0076160
qbsp: experimental func_illusionary_visblocker
2017-10-24 22:17:10 -07:00
Eric Wasylishen
b85d627c8f
change branding to ericw-tools
2017-10-19 16:35:37 -06:00
Eric Wasylishen
7a7d3b843c
qbsp: add bsp2 check if int16_t nodes/leafs are exceeded
2017-10-19 16:19:47 -06:00
Eric Wasylishen
bcf3f2e3e3
qbsp: add _external_map_scale key for misc_external_map
2017-10-01 12:39:15 -06:00
Eric Wasylishen
d4f3e5de65
qbsp: partially revert "csg: mirror faces, even for solid, to help leaf content assignment" and turn it into a flag
...
(comit a910dd861a )
fixes https://github.com/ericwa/tyrutils-ericw/issues/175 (swtest2.map)
2017-09-16 11:18:30 -06:00
Eric Wasylishen
1ac4bf5a6b
qbsp: hack to fix slightly off grid overlapping brushes having missing the overlapping parts deleted after CSG
...
fixes https://github.com/ericwa/tyrutils-ericw/issues/174
2017-09-15 21:08:04 -06:00
Eric Wasylishen
d195c0bd2a
qbsp: add _mirrorinside key for func_water, etc.
2017-08-27 12:14:09 -06:00
Eric Wasylishen
a910dd861a
qbsp: csg: mirror faces, even for solid, to help leaf content assignment
...
Mark them as skip so they don't get saved.
This fixes csg_fail.map (in combination with -epsilon 0.1)
2017-07-24 23:12:37 -06:00
Eric Wasylishen
38a7d6a944
qbsp: expose PointInLeaf as debug helper
2017-07-24 22:57:43 -06:00
Eric Wasylishen
a936686fe5
qbsp: allow empty leak lines for pathological maps (single brush)
2017-07-24 18:07:40 -06:00
Eric Wasylishen
c300170752
qbsp: disable q3map stuff
2017-07-24 14:13:57 -06:00
Eric Wasylishen
9377663e3c
qbsp: fix rejecting valid brushes in SplitBrush
2017-07-23 16:29:00 -06:00
Eric Wasylishen
51fa4dc056
qbsp: expose WriteBspBrushMap
2017-07-23 14:20:35 -06:00
Eric Wasylishen
8bfe9b4602
qbsp: exportobj.cc: helpers for exporting face/brush vectors
2017-07-23 14:15:10 -06:00
Eric Wasylishen
3efc9c1f3e
qbsp: make Contents_Priority public
2017-07-23 14:08:34 -06:00
Eric Wasylishen
39aa7dcd0f
qbsp: add FilterStructuralBrushesIntoTree
2017-07-23 13:13:09 -06:00
Eric Wasylishen
b38c04b372
qbsp: clean up brush memory leaks
2017-07-23 13:12:14 -06:00
Eric Wasylishen
7c49d499c2
qbsp: tidy FreeBrushes
2017-07-23 02:48:58 -06:00
Eric Wasylishen
2ee9017879
qbsp: test brush contents are propogated by SplitBrush
2017-07-23 01:55:53 -06:00
Eric Wasylishen
120dfda49a
qbsp: small test refactor
2017-07-23 01:51:46 -06:00
Eric Wasylishen
578d24951d
qbsp: fix memory corruption in SplitBrush
2017-07-23 01:51:31 -06:00
Eric Wasylishen
9629134612
qbsp: fix some issues with SplitBrush
2017-07-23 01:32:04 -06:00
Eric Wasylishen
3bb22ef22b
qbsp: add SplitBrush from q3map (not yet tested)
2017-07-23 00:42:09 -06:00
Eric Wasylishen
d246d2a798
qbsp: add FlipWinding
2017-07-22 23:53:33 -06:00
Eric Wasylishen
1859a1c0b5
qbsp: make DivideWinding saner + const
2017-07-22 21:29:04 -06:00
Eric Wasylishen
11a7e7bc88
qbsp: refactor BrushMostlyOnSide to take separate normal/dist
2017-07-22 19:36:55 -06:00
Eric Wasylishen
b8dec3ed2b
qbsp: add ChopWindingInPlace from q3map
2017-07-22 19:30:51 -06:00
Eric Wasylishen
3c7ea88c37
qbsp: add CopyBrush
2017-07-22 18:20:03 -06:00
Eric Wasylishen
5158b6d296
qbsp: add BoundBrush (from q3map)
2017-07-22 17:09:03 -06:00
Eric Wasylishen
7ef5ad162d
qbsp: add BrushMostlyOnSide (from q3map)
2017-07-22 17:05:09 -06:00
Eric Wasylishen
9868c7f965
qbsp: Add BrushVolume
2017-07-22 16:33:26 -06:00
Eric Wasylishen
7d1dc71069
qbsp: add Face_Plane
2017-07-22 16:31:26 -06:00
Eric Wasylishen
bca6a55662
qbsp winding: add WindingArea
2017-07-22 16:31:21 -06:00
Eric Wasylishen
0ebbdac5f9
qbsp: refactor FindPlane
2017-07-17 21:24:32 -06:00
Eric Wasylishen
a34f3df88d
qbsp: surfaces.cc: use std::map for vertex hashing
2017-07-17 16:35:11 -06:00
Eric Wasylishen
3e9e388545
qbsp: surfaces.cc: refactor vertex hashing
2017-07-17 16:06:03 -06:00
Eric Wasylishen
fc7a085893
qbsp: surfaces.cc: rewrite edge hash to use std::map
...
ad_test1.map compiles to a binary-identical .bsp
2017-07-17 16:05:46 -06:00
Eric Wasylishen
8b9f5ea40a
qbsp: fix handling of duplicate planes
...
fixes spurious leak in e1m4.map
2017-07-15 13:51:26 -06:00
Eric Wasylishen
ceff3bba82
qbsp: fix const warning
2017-07-15 12:37:15 -06:00
Eric Wasylishen
1a15d5f0e9
qbsp: add -leaktest option (from q2)
2017-07-15 12:23:11 -06:00
Eric Wasylishen
0263f95e59
qbsp: add -expand flag from q3map for testing hull1 expansion
2017-07-11 17:54:28 -06:00
Eric Wasylishen
2710f9b1a1
qbsp: remove/comment dead code
2017-07-11 00:07:32 -06:00
Eric Wasylishen
be2799578f
qbsp: remove dead code (extrafaces)
2017-07-11 00:05:57 -06:00
Eric Wasylishen
53743ddf0e
qbsp: SubdivideFace: revert change to splitting logic from 1630b87
...
Fixes #160
2017-07-10 21:46:14 -06:00
Eric Wasylishen
f54abd9a2c
qbsp: WriteBSPFile: print the bsp file name to the log
2017-07-10 21:26:06 -06:00
Eric Wasylishen
240d65f788
qbsp: outside.cc rewrite
...
- no more recursively traversing portals, as this can overflow the stack
- better outside filling and .pts file generation, inspired by q3map
(do a bfs from all leafs with entities, storing the number of steps
from an occupied leaf in each leaf. Then do a dfs from the outside node
to the first entity we hit.)
- .por file writing was dropped for now, can be re-added later
2017-07-10 12:46:22 -06:00
Eric Wasylishen
bb3e296a0d
qbsp: FillOutside: count portals yourself
2017-07-09 01:06:49 -06:00
Eric Wasylishen
3069996a6f
qbsp: portals.cc: remove statics, move to portal_state_t struct
2017-07-09 00:46:06 -06:00
Eric Wasylishen
e848d00f92
qbsp: get an actual test for #158 , currently disabled
2017-07-08 17:38:33 -06:00
Eric Wasylishen
01fa4a9f58
qbsp: set up test case for #158
2017-07-08 16:23:08 -06:00
Eric Wasylishen
34a6bf7876
qbsp: add testqbsp target
2017-07-08 15:49:14 -06:00
Eric Wasylishen
7656d5c2f1
qbsp: external map: merge all brush entities with worldspawn
2017-07-07 20:26:27 -06:00
Eric Wasylishen
a4e3a3a887
Revert "qbsp: move node_t markfaces list to a std::vector"
...
This reverts commit 31df408333 .
2017-07-05 18:10:56 -07:00
Eric Wasylishen
cef3b3da9f
qbsp: misc_external_map: add "_external_map_angles" for pitch/yaw/roll
2017-07-05 15:13:09 -06:00
Eric Wasylishen
cf6af89bdf
qbsp: fix some comments
2017-07-03 17:48:43 -06:00
Eric Wasylishen
117f568cd7
qbsp: don't write unused texinfo.
...
also cleanup planes writing
2017-07-03 01:58:26 -06:00
Eric Wasylishen
31df408333
qbsp: move node_t markfaces list to a std::vector
2017-07-02 21:03:41 -06:00
Eric Wasylishen
97787e9d2c
qbsp: add extrafaces argument to MakeFaceEdges
2017-07-02 20:06:41 -06:00
Eric Wasylishen
eef45d79eb
qbsp: more refactoring GrowNodeRegion
2017-07-02 17:27:35 -06:00
Eric Wasylishen
014770b212
qbsp: refactor GrowNodeRegion
2017-07-02 17:18:19 -06:00
Eric Wasylishen
d7e90b1cf2
qbsp: PrintBSPFileSizes: reformat
2017-07-02 16:34:55 -06:00
Eric Wasylishen
80380fa7fd
qbsp: drop ExportNodePlanes. Planes were already deduplicated by
...
FindPlanes.
2017-07-01 17:25:02 -06:00
Eric Wasylishen
af264821b7
mathlib: factor out SetPlanePts
2017-06-20 14:39:15 -06:00
Eric Wasylishen
85a6b9095d
qbsp: refactor PlaneInvEqual
2017-06-20 13:07:17 -06:00
Eric Wasylishen
73ffb37417
misc_external_map: fix -onlyents
2017-06-15 17:38:49 -06:00
Eric Wasylishen
37ed11c2ed
qbsp: experimental "misc_external_map" entity
...
"_external_map" - map to load
"_external_map_classname" - classname to switch to (e.g. func_wall)
"_external_map_angle" - rotation angle around Z axis
2017-06-15 03:43:39 -06:00
Eric Wasylishen
ceab425885
map.cc: factor out plane-points setting code
2017-06-15 03:30:02 -06:00
Eric Wasylishen
8d2a257729
wad.cc: factor out .wad file opening
2017-06-15 03:29:55 -06:00
Eric Wasylishen
19dd7b1c4a
qbsp: log number of planes after calling Brush_LoadEntity
2017-06-10 01:15:49 -06:00
Eric Wasylishen
77f3da30bf
qbsp: add func_detail_fence
2017-06-09 15:13:13 -06:00
Eric Wasylishen
7198884392
qbsp: ExportDrawNodes: add assertion from DP that node children are different
...
DetailToSolid: collapse redundant nodes where both children are
solid (-1) to just be the leaf -1. Any faces on-node should be
impossible to see so they can be safely discarded.
2017-06-09 13:14:52 -06:00
Eric Wasylishen
d01b740b5b
qbsp: add -omitdetailwall and -omitdetailillusionary
2017-06-07 14:12:02 -06:00
Eric Wasylishen
37401937ae
qbsp: fix LinkNodeFaces documentation
2017-06-07 12:23:25 -06:00
Eric Wasylishen
5f4520ee8b
exportobj.cc: remove redundant #defines
2017-06-05 20:29:36 -06:00
Eric Wasylishen
44445becb8
qbsp: rename "_nosurfacefragment" to func_detail_wall
2017-06-05 16:22:15 -06:00
Eric Wasylishen
f8f007f7df
qbsp: detail brushes with CFLAGS_DETAIL_NOSURFACEFRAGMENT don't
...
clip ordinary detail brushes, only those that also have the flag set
2017-06-05 16:11:04 -06:00
Eric Wasylishen
3ca83ea46e
qbsp: add logging for func_detail_illusionary and _nosurfacefragment
2017-06-05 14:37:40 -06:00
Eric Wasylishen
ac78efed98
qbsp: func_detail rewrite.
...
- Fix corrupt VIS issues when using func_detail
- func_detail no longer seals the map.
- add func_detail_illusionary entity type
- add func_detail key "_nosurfacefragment"
2017-06-05 14:09:31 -06:00
Eric Wasylishen
ea099775ef
qbsp, light: allow _shadow -1 to disable shadows from func_detail
2017-06-05 14:01:12 -06:00
Eric Wasylishen
e3da31b308
writebsp.cc: Assert we never write a private contents type to the bsp
2017-06-05 14:00:01 -06:00
Eric Wasylishen
dffee91191
csg4.cc: refactor if() statement to match comment
2017-06-01 19:40:06 -06:00
Eric Wasylishen
8236efa613
csg4.cc: clarify SaveInsideFaces docs and add assertions
2017-06-01 14:25:14 -06:00
Eric Wasylishen
e3b7b9615a
qbsp: fix check for needing PRT2 (unlikely to matter on real maps)
2017-06-01 01:16:36 -06:00
Eric Wasylishen
213e4b9f7d
qbsp: add a -nodetail switch, for debugging func_detail issues
2017-05-31 23:23:53 -06:00
Eric Wasylishen
f5d4cd9202
qbsp: add -forceprt1 option for generating a PRT1 to load in editors
...
This is for previewing the portals between clusters, since no editors
can load PRT2.
2017-05-31 23:18:04 -06:00
Eric Wasylishen
8385797ce7
csg4.cc: add a clarifying comment
2017-05-31 13:09:42 -06:00
Eric Wasylishen
224b0c4d2e
qbsp: "Couldn't create brush faces": print .map line number
2017-04-30 19:05:01 -06:00
Eric Wasylishen
85a4249852
qbsp: csg: make hint brushes never clip anything else.
2017-04-30 12:39:12 -06:00
Eric Wasylishen
8f4b506608
qbsp: refactor cmake setup
2017-04-28 13:04:51 -06:00
Eric Wasylishen
64efc77055
qbsp: expose some stuff in qbsp.hh
2017-04-28 13:04:44 -06:00
Eric Wasylishen
3ec36f6550
qbsp: use common/cmdlib
2017-04-26 15:08:49 -06:00
Eric Wasylishen
a548ada3d0
qbsp: fix build
2017-04-26 14:57:23 -06:00
Eric Wasylishen
32eaa99d40
qbsp: rename our plane_t to qbsp_plane_t
2017-04-26 14:55:26 -06:00
Eric Wasylishen
8c89e128c7
qbsp: drop internal mathlib
2017-04-26 14:51:27 -06:00
Eric Wasylishen
902c45c946
all: make VectorCompare take an explicit epsilon
2017-04-26 14:20:45 -06:00
Eric Wasylishen
68b084a6c3
replace glm with qvec
2017-04-24 00:26:49 -06:00
Eric Wasylishen
1f7bd69385
qbsp: optimize FindTexinfo
2017-04-22 16:59:14 -06:00
Eric Wasylishen
43798edcfe
qbsp: split out winding.hh
2017-04-20 20:09:24 -06:00
Eric Wasylishen
9034eb107a
qbsp: move remaining headers to include directory
2017-04-20 19:52:06 -06:00
Eric Wasylishen
c34d958d7a
qbsp: split up qbsp.hh
2017-04-20 19:44:10 -06:00
Eric Wasylishen
66744e33e2
qbsp: map conversion: output epairs in the correct order
2017-03-27 19:36:53 -06:00
Eric Wasylishen
30b8503ccf
qbsp: -convert quake: silence annoying warnings
2017-03-26 17:46:31 -06:00
Eric Wasylishen
73082828b4
qbsp: don't use regex stuff, doesn't work on the travis version of gcc
2017-03-26 17:41:22 -06:00
Eric Wasylishen
ed89dc487a
qbsp: add docs for -convert option
2017-03-26 17:07:52 -06:00
Eric Wasylishen
62f17545b9
qbsp: expose LoadBrush in header
2017-03-26 16:41:16 -06:00
Eric Wasylishen
af355a87be
qbsp: fix -convert quake2
2017-03-26 16:35:26 -06:00
Eric Wasylishen
f3caed2f8b
qbsp: support -convert quake2 to write classic q2/q3 format with three 0 flags
2017-03-26 16:06:21 -06:00
Eric Wasylishen
32b001b4d9
qbsp: fix typo in QuakeEd .map conversion
2017-03-26 16:05:33 -06:00
Eric Wasylishen
dbec32efaf
qbsp: -convert bp: write 0 0 0 face flags
2017-03-26 15:49:15 -06:00
Eric Wasylishen
8294e1d750
qbsp: change -convert valve220 to shorter -convert valve
2017-03-26 15:32:58 -06:00
Eric Wasylishen
75c3fdadf6
qbsp: rewrite .map printing code. Print as integers if it can be done losslessly.
2017-03-26 15:29:36 -06:00
Eric Wasylishen
2fe14087db
qbsp: QuakeEd .map conversion: normalize shifts
2017-03-26 15:08:10 -06:00
Eric Wasylishen
6c336738c4
qbsp: QuakeEd .map conversion: drop the RMSE test as it sometimes picked worse visual results (wood roof trim in ad_swampy)
2017-03-26 14:42:13 -06:00
Eric Wasylishen
39c137c2a3
qbsp: SetTexinfo_QuakeEd_New: treat scale=0 as scale=1
2017-03-26 13:00:07 -06:00
Eric Wasylishen
94ba5560c7
qbsp: fix QuakeEd map conversion
2017-03-26 12:40:06 -06:00
Eric Wasylishen
ce673b813e
qbsp: remove dead code
2017-03-23 14:40:03 -06:00
Eric Wasylishen
5fae648506
qbsp: refactor TexDef_BSPToValve
2017-03-23 14:39:34 -06:00
Eric Wasylishen
57bed163be
qbsp: change "brushprimtivies" label to shorter "bp"
2017-03-23 14:38:08 -06:00
Eric Wasylishen
78d517a99d
qbsp: remove placeholder entity inserted at the end of the vecotr
2017-03-22 19:22:23 -06:00
Eric Wasylishen
6f17758fc7
qbsp: quake/valve map output: avoid divide by 0 when calculating scale
2017-03-22 18:27:13 -06:00
Eric Wasylishen
be78da93e8
qbsp: quark ETP: add missing negative sign to match bjptools-xt output
2017-03-22 17:13:36 -06:00
Eric Wasylishen
fc2b5e438d
qbsp: brush primitives output
2017-03-22 16:39:43 -06:00
Eric Wasylishen
e8a7e55bb7
qbsp: refactoring to SetTexinfo_BrushPrimitives
2017-03-22 16:39:43 -06:00
Eric Wasylishen
3dda0e9c4e
qbsp: hook up "to quake" conversion
2017-03-22 02:39:55 -06:00
Eric Wasylishen
aab47605bb
qbsp: add TexDef_BSPToQuakeEd()
2017-03-22 02:12:16 -06:00
Eric Wasylishen
f04f34524c
qbsp: TextureAxisFromPlane: add extra param for returning the snapped axis
2017-03-22 01:11:21 -06:00
Eric Wasylishen
1f3d38a611
qbsp mathlib: add helper for getting angle between vectors
2017-03-22 01:07:32 -06:00
Eric Wasylishen
8e1b7effca
qbsp: mark unreachable code
2017-03-22 00:40:33 -06:00
Eric Wasylishen
c2bb2bea32
qbsp: first draft of * to valve220 conversion
2017-03-21 21:01:10 -06:00
Eric Wasylishen
d607aa1a89
qbsp: whitespace fix
2017-03-21 21:01:10 -06:00
Eric Wasylishen
a6f56d9111
qbsp: add -omitdetail option
2017-02-27 13:26:01 -07:00
Eric Wasylishen
2673d9d8c3
qbsp: fix broken clipping hulls on rotating objects
2017-01-25 14:59:40 -07:00
Eric Wasylishen
cc71ad024f
qbsp: origin brush support
...
light: allow model offset on any brush entity with "origin" key set, not just ones with a "rotate_*" classname
2017-01-24 21:39:03 -07:00
Eric Wasylishen
986aad52c2
qbsp: save _mincolor to the .texinfo file
2016-11-02 17:10:01 -06:00