Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / CreateImageFromMemblock - not working as expected

Author
Message
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 17th Feb 2016 09:50
Below is a small code snippet.
I would expect the result to be:
256
256
32

But the result I get is:
256
0
0

Maybe I'm doing something wrong or maybe there is an issue with one of the commands.

Any suggestions?

AGK V2 user - Tier 1 (mostly)
Digital Awakening
AGK Developer
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 17th Feb 2016 10:04
Not into this but shouldn't it be bytes 0, 4 and 8?
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 17th Feb 2016 10:07
No it shouldn't.
if they were bytes then you would be limited to images of no bigger then 256x256.
Width, height and depth are represented by 4 bytes (hence the offset) 4 bytes = 1 integer.
AGK V2 user - Tier 1 (mostly)
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 17th Feb 2016 10:09
Oops!
My bad.

I see what you mean now. The offsets should be 0, 4 and 8!
AGK V2 user - Tier 1 (mostly)
Digital Awakening
AGK Developer
22
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 17th Feb 2016 10:53
Hope that works for you

Login to post a reply

Server time is: 2024-09-29 11:22:22
Your offset time is: 2024-09-29 11:22:22