yquake2/yquake2remaster

How does retexture support works

Closed this issue · 2 comments

Something that Q2R doesn't support is map retexture support as YQ2, but it was never explained how yamagi and other ports makes textures fit with the map size textures since Q2R stretches them out.

is it possible to explain how it is it possible does this works?

0lvin commented

With r_retexture >=2 all palette based images and cinematic is scaled 2 or 3 times by https://en.wikipedia.org/wiki/Pixel-art_scaling_algorithms if no bigger image override is availed.

With r_retexture is bigger than zero, if exist image same name and with different extension like JPG/PNG instead WAL and has bigger resolution such image used instead original one. So image just is overrode.

Note: all renders scale all coordinates in textures by difference between original image resolution and new one. So if original image fit 256x256 for whole plane, new one also will cover whole plane. But it works only in case when you have both images old one(wal) and new one(PNG) are exist as engine needs both images for get scale.

Look to load high color image

0lvin commented

Could you please reopen if you have further questions?