Commit Graph

13 Commits

Author SHA1 Message Date
Garux d19b3c9a28 * picomodel::obj: support polygons > quads 2019-01-10 16:29:38 +03:00
Garux 034f06f18d * brushexport plugin: write Kd (diffuse color) and map_Kd (diffuse map) data to .mtl
* brushexport plugin fix: invert Y during YZ swap; invert V of UV coords (correct texturing)
	* brushexport plugin: default to 'Don't collapse' option
q3map2:	* obj export: save in popular 'Y = Up, -Z = Forward' format
	* picomodel::obj: load as popular 'Y = Up, -Z = Forward' format
	* picomodel::obj: fix support of back references in faces
2019-01-10 00:44:27 +03:00
Zack Middleton 9aa9620d4d Fix over allocating vertexes for OBJ models with multiple surfaces
Loading Wavefront OBJ models in picomodel (used by radiant and q3map2)
did not reset the surface vertex index when starting a new surface. This
caused there to be unused vertexes, equal to the number of vertexes in
all previous surfaces, at the beginning of each surface. Exponential OBJ
vertex memory usage as number of surfaces increases. It did not affect
displaying or processing the surface faces.
2018-10-30 20:27:44 -05:00
Garux 86904473bb * picomodel: do some guessings about shader paths to handle more cases out of the box; ones are based on material and diffuse map names:
name w/o path: assume textures are in the folder, where model file is
		absolute path or with ..: try to cut at "/models/" or "/textures/" (as if leading to game folders); do previous case, if not
		strip extensions and turn slashes to forward ones anytime
	* picomodel::obj: fix diffuse map paths loading from .mtl
2018-09-29 14:39:10 +03:00
Garux 47ef9a6ae2 * picomodel::obj: fix black default vertex color, also use one from .mtl 2018-07-14 20:52:17 +03:00
Garux e3fd576624 Q3map2:
code fixes

Radiant:

binds...
	* m1x2 on clipper point = do clip
menus...
	* misc->colors->opengl font selector
misc...
	* calculate farplane from g_MaxWorldCoord, g_MinWorldCoord (was const 32768)
	* 1.0f nearplane
	* numerous code fixes
2017-08-02 09:25:58 +03:00
Nodenum 805046c354 Fix bug #1356: .obj loading bug in picolib
There's a bug in picolib when parsing the first group in an .obj file.

The library tries to set the surface name to a surface pointer
that is still NULL.

This gets silently ignored but the problem reappears later
in a warning message when the material or a face is parsed.
2012-12-17 09:32:19 +01:00
Rudolf Polzer e4287c28bb my own uncrustify run 2012-03-27 12:03:21 +02:00
Rudolf Polzer 028fc5286c hide another "error" 2011-05-22 20:35:37 +02:00
Rudolf Polzer d9f3f840b7 turn two picomodel errors into warnings 2011-04-12 20:40:19 +02:00
rpolzer 5ec3a47e10 q3map2 is now waring free 2010-10-05 10:57:07 +02:00
divverent be63f42ed5 picomodel: support OBJs without material groups
git-svn-id: svn://svn.icculus.org/netradiant/trunk@219 61c419a2-8eb2-4b30-bcec-8cead039b335
2009-03-13 09:26:45 +00:00
rpolzer 107765f0e4 initial
git-svn-id: svn://svn.icculus.org/netradiant/trunk@1 61c419a2-8eb2-4b30-bcec-8cead039b335
2008-09-13 18:28:57 +00:00