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.

Dark GDK / VS.Net resource and DGSDK 'media' index/numbering...

Author
Message
Lampton Worm
22
Years of Service
User Offline
Joined: 4th Sep 2002
Location: United Kingdom
Posted: 14th Aug 2005 20:15
Hi,

Is it possible to add media to a VS.Net project and then use a DGSDK media load command (e.g. dbLoadImage) to load from there somehow?

For example, if I right click on my proj and go Add>Existing Item>BMP thats grand, but how would I get that BMP assigned to DG's equiv of dbLoadImage..

Basically can it be used in a simular way to how I'd have used 'add media' in the DBP editor previously? (i.e. I don't want to ship separate media and a game exe, want it bundled into one).

Cheers
OSX Using Happy Dude
21
Years of Service
User Offline
Joined: 21st Aug 2003
Location: At home
Posted: 14th Aug 2005 23:04
Quote: "Is it possible to add media to a VS.Net project and then use a DGSDK media load command (e.g. dbLoadImage) to load from there somehow?"

Not as default - you could get the bitmap resource, create it in memory and then get DBPro to make an image from that (ie a memblock)

The main problem is working out the bitmap format when an image is in a resource. I did have example code for it in the Code Snippet (or possibly WIP area) which worked, but everything was guess work (could never find the layout details).

AtomZ - its got an A. Its got a Z. Now its just needs U
Blog:http://spaces.msn.com/members/BouncyBrick/
Web Site:http://www.nicholaskingsley.co.uk
Lampton Worm
22
Years of Service
User Offline
Joined: 4th Sep 2002
Location: United Kingdom
Posted: 21st Aug 2005 13:25
Hi ya,

Do you happen to have a link to the code you mentioned?

Cheers.
OSX Using Happy Dude
21
Years of Service
User Offline
Joined: 21st Aug 2003
Location: At home
Posted: 21st Aug 2005 14:04
Here you go : http://forum.thegamecreators.com/?m=forum_view&t=25249&b=8

Come to the third DarkBasic Pro Sci Fi Con - Be there and be square
Blog:http://spaces.msn.com/members/BouncyBrick/
Web Site:http://www.nicholaskingsley.co.uk
Lampton Worm
22
Years of Service
User Offline
Joined: 4th Sep 2002
Location: United Kingdom
Posted: 21st Aug 2005 16:26
Hi,

Thanks I'll have a look at that.

Also , don't get me wrong, I'm after all the help I can get - but I'm hoping the code to do what I need will be 'fairly' simple, e.g. maybe use a DX command to get the resource into memory (it may already be there if I've added it to the project?) then use the memblock commands as you suggest to make the image from that location, then load the image as standard.

Cheers
OSX Using Happy Dude
21
Years of Service
User Offline
Joined: 21st Aug 2003
Location: At home
Posted: 21st Aug 2005 20:14
I dont think there are any DirectX functions to load in images directly from a resource, hence the rather cumbersome code. I have suggested to Mike it would be A Good Idea to add one in DBPro/SDK

Come to the third DarkBasic Pro Sci Fi Con - Be there and be square
Blog:http://spaces.msn.com/members/BouncyBrick/
Web Site:http://www.nicholaskingsley.co.uk
Lampton Worm
22
Years of Service
User Offline
Joined: 4th Sep 2002
Location: United Kingdom
Posted: 22nd Aug 2005 13:06
Ah ok, thanks. Hope it makes a release soon On that subject, do you happen to know if/when the enhancement commands are coming to DGSDK?

Cheers!
OSX Using Happy Dude
21
Years of Service
User Offline
Joined: 21st Aug 2003
Location: At home
Posted: 22nd Aug 2005 13:54
No idea - possibly on the new blue moon...

Come to the third DarkBasic Pro Sci Fi Con - Be there and be square
Blog:http://spaces.msn.com/members/BouncyBrick/
Web Site:http://www.nicholaskingsley.co.uk

Login to post a reply

Server time is: 2024-11-19 01:22:52
Your offset time is: 2024-11-19 01:22:52