Viech wrote:
As mentioned earlier, please keep in mind that no serious map uses actual light entities as they have always produced really bad results (either light without a source or light souces that are lit more brightly than the area they are supposed to light). I can imagine that q3map2 internally generates light entities for light emitting shaders (which are used by the hundreds in every map), too, but it may be that a whole collection of directed and undirected lights are generated like this per single light source. Hence it is possible that the amount of "internal light entities" that q3map2 considers goes into the thousands.
It looks like q3map2 just generate multiple pointlights in front of "light emitting shaders", you say how many the surface must be subdivided (which computes how many pointlights for a same surface) and the distance of these pointlights. If you don't subdivise it a lot, you just get some big globs (you can see them on my metro screenshot above, even with light emitting shaders). This is why for example you get all these wrongly casted shadows since the shadows are casted from all these pointlights from subdivisions.
Btw, this is some work I did with some conversion (q3map2 bsp to ase, assimp ase to 3ds):
faces (automatic conversion)

fullbright (automatic conversion)

fast lighting (light emitting shaders remade by hand, just to see how it works)

q3map2 can export bsp to obj or ase. Blender can import obj without external plugins, assimp can convert ase to some formats Blender can import without external plugins like 3ds, ade (collada). I strongly hope we can use that ade interchange format for blender import since it's the fastest I tried (there is also a dedicated library for that task, that's probably why it's fast), badly, the current ade imports references textures but something goes wrong (they are full transparent and without diffuse), probably something to fix somewhere in assimp.
q3map2 can export bsp to obj or ase but do not export curved mesh, that is very bad, perhaps it's a limitation of obj? I don't know for ase but these curved meshes are dropped too. This must be fixed.
q3map2 knows how to convert q3 shaders in mtl or internal ase format, but only does it for diffuseMap textures, it must be extended to export specular, normal and other special textures. It must also be extended to convert light emitting shader informations (we can think of adding new keywords that target the final renderer if the final renderer handles stuff q3map2 don't do).
This is how I load a map in blender:
first, convert all textures to tga:
Code: Select all
find $(find * -maxdepth 0 -type d | grep -v build) -name '*.jpg' -o -name '*.png' -o -name '*.webp' | while read j; do t=$(echo $j | sed -e 's/\.jpg$/.tga/;s/\.png/.tga/;s/\.webp/.tga/'); convert $j $t; done
then compile the map:
Code: Select all
q3map2 -game unvanquished -fs_pakpath /data/unvanquished/pkg/ -fs_pakpath . -bsp -meta -custinfoparms -samplesize 16 maps/rsmse.map
q3map2 -game unvanquished -vis -saveprt maps/rsmse.bsp
then convert to obj+mtl:
Code: Select all
q3map2 -game unvanquished -fs_pakpath /data/unvanquished/pkg/ -fs_pakpath . -convert -format obj maps/rsmse.bsp
to convert to dae or 3ds I do:
Code: Select all
q3map2 -game unvanquished -fs_pakpath /data/unvanquished/pkg/ -fs_pakpath . -convert -format ase maps/rsmse.bsp
assimp export maps/rsmse.ase maps/rsmse.dae -fcollada
assimp export maps/rsmse.ase maps/rsmse.3ds -f3ds