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.

Newcomers DBPro Corner / Save image problem in db pro

Author
Message
elie
20
Years of Service
User Offline
Joined: 12th Sep 2004
Location:
Posted: 17th Jan 2005 23:48
Hi folks ...

I have created a screen 1024x768, followed by a get image command 0,0,1024,768 ( so in theory grabbing the whole screen )

now when i use the save image command it saves it with a 1024x1024 size and streaches the image to match .... any ideas what im doing wrong and how to stop this happening ?

thanx
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 18th Jan 2005 02:39 Edited at: 18th Jan 2005 02:40
Use get image 0,0,1024,768,1

The extra 1 at the end keeps it from squaring it.

elie
20
Years of Service
User Offline
Joined: 12th Sep 2004
Location:
Posted: 18th Jan 2005 08:03
thanx buddy - my head can stop hurting now
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 18th Jan 2005 15:46
Glad you got it working

Opus
19
Years of Service
User Offline
Joined: 10th Jan 2005
Location:
Posted: 20th Jan 2005 22:12
To clarify, the following syntax rules come from DarkBasic Professional's Tutorial on Screen Scrolling. It was created in January of 2003, but the information should remain valid.

If you specify an additional "0" at the end of the "get image" command, this tells DBPro that the image is going to be used for a texture. On the other hand, by using a "1" for the parameter, instead of a "0", DBPro will attempt to use a pixel perfect image, which would be fine until the point where you wish to scroll the image, whereupon the image would become corrupt.

I hope that this information helps.

So, I guess it boils down to whether or not you wish to scroll the image.

Login to post a reply

Server time is: 2024-11-27 19:29:33
Your offset time is: 2024-11-27 19:29:33