Texture scaling fix?

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
User avatar
Xaser
 
 
Posts: 10774
Joined: Sun Jul 20, 2003 12:15 pm

Texture scaling fix?

Post by Xaser »

Okay, a while back, I remember a discussion on scaling textures and offsets and such. Normally, the standard behavior is that when you scale the texture, offsets still only affect the individual pixels of the texture, meaning that if you scale an object in half, you must double the offsets in order for it to look correct. Here's a quote from a certain wiki page.
Whoever made the wiki page I just linked to wrote:When a texture is scaled, the way it is aligned is affected. If the texture is scaled to be half-size, the offset (in the map editor, not the texture definition) for that texture must be doubled in order to achieve desired results. If the texture is quarter-size, the offset must be quadrupled, and so on.
I'm not sure whether this is just a case of my memory failing it or not, but wasn't there some type of option implemented a while back that allowed you to scale textures by world units, so you wouldn't have to double the textures and stuff? I can't find any information about that particular subject, but I swear, I remember it being put in there somehow...

Does anyone here know if this fix exists, and if it does, how to use it?

Well, thanks in advance.
User avatar
Enjay
 
 
Posts: 27512
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Post by Enjay »

Yes, this option does exist, and you set it in the texture1 lump.

I've no idea what hex values or free fields or whatever would need to be set in an editor that didn't explicitly support them, but in DeePSea when you create your scaled texture, there is also the option (in the form of a tick box) to offset the texture by "world units" or leave it blank for the default of pixel by pixel offsetting. So it's not a global variable or anything, it's set on a per texture basis.
User avatar
Nash
 
 
Posts: 17512
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia

Post by Nash »

I'd like more information on this please. :) I use a lot of high-res textures and DB just won't auto-align them properly. :(

Thought I don't think this extra option can be set from XWE because the TEXTUREx editor in XWE doesn't have any more extra fields. :(
User avatar
Xaser
 
 
Posts: 10774
Joined: Sun Jul 20, 2003 12:15 pm

Post by Xaser »

Ah, thanks Enjay. So it does exist. :P

Well, I looked, and Nash is right. XWE doesn't have an option to set this, and DeePsea doesn't work at all for me (because it's being annoying), so I'm pretty stumped on how to do this. Well, at least I know that if somehow I can get DeePSea working, that might work. :P
User avatar
Enjay
 
 
Posts: 27512
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland

Post by Enjay »

Nash wrote:I'd like more information on this please. :)
Not sure what you mean by more information. That's about all there is to it.

It's been covered in these threads. Risen mentions how to get it to work in XWE in the second one.

http://forum.zdoom.org/potato.php?p=8227

http://forum.zdoom.org/potato.php?p=75571

http://forum.zdoom.org/potato.php?p=106698
User avatar
Hirogen2
Posts: 2033
Joined: Sat Jul 19, 2003 6:15 am
Operating System Version (Optional): Tumbleweed x64
Graphics Processor: Intel with Vulkan/Metal Support
Location: Central Germany

Post by Hirogen2 »

Yeah, extra flag 0x8000.
User avatar
Nash
 
 
Posts: 17512
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia

Post by Nash »

Thanks a lot, Enjay. That really solved my problems with high-res textures!

XWE should turn it into a checkbox too, or something hehe. :)

EDIT: I have edited the Wiki information, documenting on the 0x8000 flag. I only added details for XWE, someone with DeePsea should edit it further. :)

http://www.zdoom.org/wiki/index.php?tit ... d_Textures

Return to “Editing (Archive)”