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.

DarkBASIC Professional Discussion / Who needs a modern basic as dbpro? Using FreeBasic ;)

Author
Message
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 25th May 2015 15:15
Keep porting the Advanced Lighting code to Freebasic. I'm in the process of converting my dbPro code to Lua to make a conversion to Freebasic easier.
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 26th May 2015 07:24
Ooooops! Now, i see it.
change line to.


Quote: "Keep porting the Advanced Lighting code to Freebasic."

Yes, I start soon my third attempt. There are some things which FreeBasic handles differently than DBPro.

But now a new release with two new plugins
New Plugins:
* DarkPhysics - because i own it
* Blitz Terrain - the free version.

Both with some examples.

The GUI for the ReleasePacker is in the testing phase.

But now my main focus is porting the AdvancedLightig code.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine

Attachments

Login to view attachments
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 5th Jun 2015 10:31
A small update what I'm doing.
I have now managed to run the first demo (Bone animation) of Advanced Lighting.

Compile time - DBPro: 17 sec. FB: 4 sec.

One with the release packer built version can be found below in the download.
Unzip this in PBpro project directory of Advanced Lighting. Because the media files are not present.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine

Attachments

Login to view attachments
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 5th Jun 2015 20:06
Looks great, carry on!

Though you might need to sync rate 60, its running at over 600fps on my machine.
wattywatts
14
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 6th Jun 2015 20:27
Quote: "its running at over 600fps on my machine."

Well now I'm paying attention to this thread. I got ~ 3x the framerate with this exe.
Stab in the Dark software
Valued Member
21
Years of Service
User Offline
Joined: 12th Dec 2002
Playing: Badges, I don't need no stinkin badges
Posted: 8th Jun 2015 08:11 Edited at: 8th Jun 2015 08:11
No change in FPS on my machine and I would not expect it to change the FPS.

WindowsXP SP3,Vista,Windows 7 SP1, DBpro v7.7RC7
Stab In The Dark Editor
The coffee is lovely dark and deep,and I have code to write before I sleep.
Mage
17
Years of Service
User Offline
Joined: 3rd Feb 2007
Location: Canada
Posted: 8th Jun 2015 09:42
How does Freebasic compare to DX9 capabilities.

I mean its nice to talk about function calls and multi threading, but how is it in the real things that matter.

Can you Load Object or equivalent. Is there animation support? Is there shader support? Sound? Controller Support? What about physics and hit detection?

Thanks

wattywatts
14
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 8th Jun 2015 09:44
Quote: "No change in FPS on my machine and I would not expect it to change the FPS."

I can screen shot it if you like.
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 8th Jun 2015 10:11
Quote: "Can you Load Object or equivalent. Is there animation support? Is there shader support? Sound? Controller Support? What about physics and hit detection?"


Madbit has made dbPro available to Freebasic via his plugin, so whatever dbPro can do, Freebasic now can too.
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 8th Jun 2015 10:26 Edited at: 8th Jun 2015 10:27
@ Mage:
Quote: "How does Freebasic compare to DX9 capabilities.

I mean its nice to talk about function calls and multi threading, but how is it in the real things that matter.

Can you Load Object or equivalent. Is there animation support? Is there shader support? Sound? Controller Support? What about physics and hit detection?"

Free Basic itself does not have DX9 commands. These are added all only through external libraries. That's exactly what I'm doing here I wrappe only DBPro DLL's so that they can be used in FreeBASIC. So that nearly all commands of DBPro is useable in FreeBASIC.


@ wattywatts
Quote: "Well now I'm paying attention to this thread. I got ~ 3x the framerate with this exe. "

That's nice to hear.

EDIT:
Ups, to slow.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
Stab in the Dark software
Valued Member
21
Years of Service
User Offline
Joined: 12th Dec 2002
Playing: Badges, I don't need no stinkin badges
Posted: 8th Jun 2015 16:52
MadBit

Can you please explain how this would increase frame rates in DBPro?

WindowsXP SP3,Vista,Windows 7 SP1, DBpro v7.7RC7
Stab In The Dark Editor
The coffee is lovely dark and deep,and I have code to write before I sleep.
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 8th Jun 2015 21:46
Yes, I was wondering that too, since I guess the same DLLs are used somehow. Perhaps I've misunderstood what's going on exactly?



Powered by Free Banners
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 9th Jun 2015 11:14
Quote: "Can you please explain how this would increase frame rates in DBPro?"

Quote: "Yes, I was wondering that too, since I guess the same DLLs are used somehow. Perhaps I've misunderstood what's going on exactly?"


Green Gandalf you're right, there are the same dll's and functions used. All functions of the engine should be run equal. There is no speed advantages.

Free Basic has advantages in loops and function calls. And these are also used in AdvancedLighting.
But such high performance gains has been reported, that surprises me.

Since AdvancedLighting is not yet completely converted there can surely still be a hidden bug. For example, a missing calculation. Or what ever.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 9th Jun 2015 14:40
Quote: "But such high performance gains has been reported, that surprises me."


Me too. Perhaps their tests were not comparable in some way? Different sync rate settings or screen resolutions/display mode perhaps?

Quote: "Since AdvancedLighting is not yet completely converted there can surely still be a hidden bug. For example, a missing calculation. Or what ever."


Quite possible.



Powered by Free Banners
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 9th Jun 2015 15:06
Resolution and displaymode are the same. Of course, sync is off.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
wattywatts
14
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 9th Jun 2015 19:11
Not sure what to say then, I turned sync off in the original demo as well and got the same results - compiled in dbp I get around 50 fps, versus about 150 in your exe.
Green Gandalf
VIP Member
19
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 9th Jun 2015 19:40
Sounds like we all need to buy your machine ...



Powered by Free Banners
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 10th Jun 2015 10:22
Quote: "Sounds like we all need to buy your machine ..."


That would be a downgrade for me, I get over 600fps on the freebasic conversion of the bones animation demo. Looking forward to seeing more get converted as my quest based RPG project uses the Advanced Lighting engine, (actually the terrain).
Stab in the Dark software
Valued Member
21
Years of Service
User Offline
Joined: 12th Dec 2002
Playing: Badges, I don't need no stinkin badges
Posted: 11th Jun 2015 06:11
I still see no proof that this would increase the FPS.

WindowsXP SP3,Vista,Windows 7 SP1, DBpro v7.7RC7
Stab In The Dark Editor
The coffee is lovely dark and deep,and I have code to write before I sleep.
wattywatts
14
Years of Service
User Offline
Joined: 25th May 2009
Location: Michigan
Posted: 11th Jun 2015 06:50
Quote: "That would be a downgrade for me, I get over 600fps on the freebasic conversion"

Well it is a surface 1, nothing too spectacular in the graphics department. However it can compile the AL demo's in ~ 10 seconds, which is quite a drastic improvement over my main pc.
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 11th Jun 2015 10:16
Yes compile times are a huge draw for me because my project has over 10 thousand lines of code. It did use to have 20 thousand (and take literally 40 seconds to compile!) but I've been converting much of it to Lua and that's drastically cut down on the amount of dbPro code. The bulk of this is the advanced lightning engine which I can't do anything about, but when it is converted to Freebasic, all I need to do is convert my dbPro code (perhaps 2000 lines now) and I should be getting compile times of a few seconds tops.
Stab in the Dark software
Valued Member
21
Years of Service
User Offline
Joined: 12th Dec 2002
Playing: Badges, I don't need no stinkin badges
Posted: 11th Jun 2015 16:12
I am not talking about compile times.
These are unfounded claims that this would increase FPS.
Where is the logic that this would change rendering.

Quote: "Since AdvancedLighting is not yet completely converted there can surely still be a hidden bug. For example, a missing calculation. Or what ever."


This implies that it is not running the same code so you can not compare.

WindowsXP SP3,Vista,Windows 7 SP1, DBpro v7.7RC7
Stab In The Dark Editor
The coffee is lovely dark and deep,and I have code to write before I sleep.
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 11th Jun 2015 21:19 Edited at: 11th Jun 2015 21:22
it would be comparable if it produces the same outcome regardless of code that achieves it just as you can compare two different algorithms that achieve the same result in different ways. with AL the performance gains may be in the data handling rather than the rendering depending on how he ported it and what code was replaced or changed. I wouldn't expect that much of a gain, but I'm curious to try it and see what happens.

the bone animation demo is fairly small and simple, I'd also be curious to see a performance comparison on a more demanding demo like the palm tree demo or terrain demo

MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 12th Jun 2015 14:27
So, again a small update of AL. The download now contains the following demos: Bone Animation, Cube Light, Directional Light, Point Light, Spot Light, Motion Blur and Palm Tree.
As before, all packed with the release packer and without media files. So Simply unzip in the existing Advanced Lighting project folder .

A little speed comparison of myself.

Test on a Laptop of my Wife (Intel i3 2350M only Integrated Graphics) a low end laptop with standard installation win7. No development things on it.
Form:
Demo - FreeBasic / DBPro / %

Bone Animation - ~65 / ~62 / +4.83%
Cube Light - ~65 / ~61 / +6.55%
Direcional Light - ~45 / ~41 / +9.75%
Motion Blur - ~32 / ~30 / +6.6%
Palmtree - ~19 / ~19 / 0.0%
Point Light - ~66 / ~60 / +10.0%
Spot Light - ~70 / ~60 / +16.6%

Second Test on my old Desktop PC (Intel Core2 6600 2.4 GHz / GeForce GTX 560 2GB Ram).

Bone Animation - ~350 / ~300 / +16.6%
Cube Light - ~360 / ~350 / +17.14%
Direcional Light - ~305 / ~300 / +1.6%
Motion Blur - ~199 / ~191 / +4.18%
Palmtree - ~110 / ~100 / +10.0%
Point Light - ~375 / ~360 / +4.16%
Spot Light - ~415 / ~360 / +15.27%

On my dev laptop no difference in speed can be observed. (Dell inspiron 17R SP GF 650M / Intel 4000 HD / i7 3630QM )

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine

Attachments

Login to view attachments
Ortu
DBPro Master
16
Years of Service
User Offline
Joined: 21st Nov 2007
Location: Austin, TX
Posted: 13th Jun 2015 08:12 Edited at: 13th Jun 2015 08:18
Test results:

system:


(fps as rough average, observed at initial views without any camera motion)

bone animation - FB 400 - DBP 330
motion blur - FB 187 - DBP 178
palm tree - FB 115 - DBP 111

I'm really inclined to believe that the gains are in the data processing and are not related to rendering, but without detailed timing and benchmarking, who knows?

also, judging by the palm tree, used in a full on game I think the difference will ultimately be negligible

Kuper
16
Years of Service
User Offline
Joined: 25th Feb 2008
Playing: Planescape:Torment
Posted: 13th Jun 2015 15:37
Whoa!
Just saw that ADvancedLighting is now on FreeBasic
My fps tests ( i7 2700k , gtx 580 )
Spot light DBPro - 584 FB - 659
Palm Tree DBPro - 163 FB - 162
Bone animation DBPro - 608 FB - 608
Directional DBPro - 423 FB - 454
So its like FB renders lights faster.I think Its good idea to make test like 10 point lights in screen.

Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 14th Jun 2015 14:04
Any chance of releasing your converted Advanced Lighting code to this point?
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 15th Jun 2015 12:42
Please wait one or two days, then I'll be hopefully ready. Terrain and material demos are already done. Now only the Particle Demo must be implemented.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 16th Jun 2015 13:42
So now I'm hopefully done. In this post you can find the converted Advanced Lighting. All project files and an additional project, so you do not must to include the complete source code of AL in your project.

Here's a little guide.
Load the project 'DBProUtil_AdvancedLighting' in your FBEdit and compile it. It create now a library. Now copy this library and the header files (*.Bi) in the include directory, into your project folder (Important maintaining directory structure (/include/ and /include/Advanced Lighting/)). Now you need only including the 'Advanced Lighting.bi'-Header.
Before you test the sample programs, it is important you build the library.

Before you work with AL you need the new (16-06-2015 or later) FBDBPro libraries (next post)

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine

Attachments

Login to view attachments
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 16th Jun 2015 13:57
This is the new release with a lot of bugfixes. There is also a new version of the release packer and a suitable GUI (Tools folder). It is recommended to integrate ReleasePacker (RPGUI) in the Tools-Menu. Use 'Option -> Tool-menu'.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine

Attachments

Login to view attachments
Burning Feet Man
16
Years of Service
User Offline
Joined: 4th Jan 2008
Location: Sydney, Australia
Posted: 19th Jun 2015 11:32
Can everyone here help me convince Balid to write a FreeBasic version of Indigo IDE?


Help build an online DarkBASIC Professional help archive.
DarkBasic Help Wikia
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 20th Jun 2015 11:42
Just downloading now. I've been on holiday for a few days so only just checking it out.
Kingius Returns
10
Years of Service
User Offline
Joined: 17th Oct 2013
Location: UK
Posted: 21st Jun 2015 16:39
Fantastic work!

I have a quick question for you ... Which files would we need to distribute in order for the full technology stack to be deployed on a target computer?
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 21st Jun 2015 22:50
Thank you.

I hope you had a nice time in your holiday.

Quote: "Which files would we need to distribute in order for the full technology stack to be deployed on a target computer? "

It depends on what commands you have use in your project. Do you use, for example, only 2D commands, you need to click 2d. It will then pack all dependent DLLs. If you're not sure, then click on all. If you use licensed or custom dll's then you have to add the correspond DLL's.

I hope this answer helps.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
Burning Feet Man
16
Years of Service
User Offline
Joined: 4th Jan 2008
Location: Sydney, Australia
Posted: 28th Jun 2015 12:11
Hi MadBit,

Working great, just wanted to thank you again for all your hard work.

Help build an online DarkBASIC Professional help archive.
DarkBasic Help Wikia
Balid
20
Years of Service
User Offline
Joined: 21st Nov 2003
Location: MI, USA
Posted: 28th Jun 2015 14:55
BFM,

Please contact me directly. I think I have good and exiting news for you .

All the best,

Burning Feet Man
16
Years of Service
User Offline
Joined: 4th Jan 2008
Location: Sydney, Australia
Posted: 30th Jun 2015 13:52
Hey MadBit,

I noticed that some FreeBasic commands crash out upon execution within a DBProLoop(), such as the FreeBasic command "getkey".

What are your thoughts on this? Obviously I can just use the DBPro commands, but I'm curious what other FreeBASIC commands are no go with this DBPro integration, and what are the pro's & con's of such a limitation (if any).

Balid, replied.

Help build an online DarkBASIC Professional help archive.
DarkBasic Help Wikia
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 1st Jul 2015 15:29 Edited at: 1st Jul 2015 15:35
[ double post ]

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 1st Jul 2015 15:34
Quote: "Working great, just wanted to thank you again for all your hard work. "


Quote: "I noticed that some FreeBasic commands crash out upon execution within a DBProLoop(), such as the FreeBasic command "getkey". "

I have tested it.

I've found out that the program does not crash but rather waiting on a keyboard input. However freebasic search in a wrong thread for the query. And so hangs the program.
If you want to test it. Then you just compile the program as a console application, select the console and then press a key.
This problem you will have in all input commands. In this case I strongly recommend to take the DBPro commands.

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
Emil_halim
9
Years of Service
User Offline
Joined: 13th Jun 2014
Location: Alex,Egypt
Posted: 2nd Jul 2015 16:37
Hi MadBit,

it is a great project , well done.

one year ago , i have started a samelire project but i combined DPPro,Ogre,irrlicht and ofcource my OgarMagic library in one project.

it has some bugs and i stopped developing it , i was using VC2012.

after seeing your project i may restart developing it with GCC , so that it works the same with FreeBasic.

http://www.freewebs.com/ogremagic/index.htm
MadBit
VIP Member
Gold Codemaster
14
Years of Service
User Offline
Joined: 25th Jun 2009
Location: Germany
Posted: 13th Jul 2015 15:44 Edited at: 13th Jul 2015 15:46
@Emil_halim
Thanks for your words. I had a look at your OgreMagic-Project looks good. But i see, you use in all cases (irrlicht and ogre) OpenGL. So if you convert it to DBPro, you must rewrite all your code in DirectX. And please take a look to other projects, there are similar to your (ImageKit, AdvancedSprites, D3DFunc, ... ) so you don't reinvent the wheel.
Or your project is much better, faster and/or easier to use

Share your knowledge. It's a way to achieve immortality. (Tenzin Gyatso)
Pixie-Particle-Engine
Emil_halim
9
Years of Service
User Offline
Joined: 13th Jun 2014
Location: Alex,Egypt
Posted: 16th Jul 2015 22:24
oh , no my new project that i was talking about relies on directX only . so there is no openGL stuff at all.

also i still do not releasing it because it has some bugs.

the point here is using FreeBasic as a programming language for developing Dark basic stuff.

http://www.freewebs.com/ogremagic/index.htm
Emil_halim
9
Years of Service
User Offline
Joined: 13th Jun 2014
Location: Alex,Egypt
Posted: 19th Jul 2015 13:02
Hi MadBit,

i have a good news , may be tomorrow , i will post the sdk of MagicPro.

here is the link page in Ogre Forum.

http://www.ogre3d.org/forums/viewtopic.php?f=11&t=25924&start=400

http://www.freewebs.com/ogremagic/index.htm

Login to post a reply

Server time is: 2024-04-19 17:32:08
Your offset time is: 2024-04-19 17:32:08