|
|
Re: save hmp file dll
[Re: sivan]
#450547
04/17/15 09:18
04/17/15 09:18
|
Joined: Mar 2012
Posts: 927 cyberspace
Wjbender
OP
User
|
OP
User
Joined: Mar 2012
Posts: 927
cyberspace
|
I have tested with
bmap_createpart bmap_createblack bmap_blitpart
with non square sizes , to try and duplicate your problem when you said it doesn't save non square skins .
but all of those saved them out , however they are filled with black to make them powers of 2, by the engine when applied as a texture skin , that's the only thing I can think of now ,that bears any kind of similarities with your problem , because I am stil not sure what functions your using so that I can try and duplicate the problem .
edit : let me look in to this a bit more
Last edited by Wjbender; 04/17/15 10:30.
Compulsive compiler
|
|
|
Re: save hmp file dll
[Re: Wjbender]
#450549
04/17/15 10:31
04/17/15 10:31
|
Joined: Mar 2011
Posts: 3,150 Budapest
sivan
Expert
|
Expert
Joined: Mar 2011
Posts: 3,150
Budapest
|
unfortunately I cannot give a simple answer as in MapBuilder I use different configurations for single skin + detail map terrains, and for multitexturing where blending is stored in the alpha channel. if you are patient enough and want to read a lot, it is within MBteredit_tx.h/.c and MBterrhmp.h/.c. later I'm planning to upload it to GitHub, it would be easier to discuss. so it is okay now, this mipmap thingie at least fixed some other issues  and I can change my shaders to use square atlas maps. currently I'm mostly using an autotexturing shader, which is much better for using with many levels than to save skins to every hmp-s (and I frequently use the same hmp for many levels beside a deformation info file), thus imo it is better if you don't invest too much time into my problem at the moment. and I'm not sure how much I will work with 3dgs in future... the dll basically works fine beside this limitation.
|
|
|
Re: save hmp file dll
[Re: sivan]
#450550
04/17/15 10:40
04/17/15 10:40
|
Joined: Mar 2012
Posts: 927 cyberspace
Wjbender
OP
User
|
OP
User
Joined: Mar 2012
Posts: 927
cyberspace
|
I found this in the manual under bmap_lock
After locking an uncompressed bitmap, you can access its texture content directly through the bmap.finalbits pointer. The texture size (in bytes) is given through (mybmap.finalwidth * mybmap.finalheight * bmap.finalbytespp). The texture size is normally a power of 2 and not identical to the original image size returned by bmap_width and bmap_height.
I just had to know why and what goes wrong
Compulsive compiler
|
|
|
|