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 / How to make a nebula

Author
Message
Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 23rd Mar 2012 21:47 Edited at: 1st Apr 2012 17:46
I need to make 3D nebulae. Here is what I have for now. Does anyone know a good method?


Here is a link to download the program:
https://docs.google.com/file/d/0BySKIgkx3OcbbzJSWWtNUTdSTEt5SU56eFoyMVByUQ/edit

It has limited functionallity.... You can rotate around by right-clicking and moving the mouse. To move the rotation center, hold [CTRL] and the right-click and move the mouse. The "star map" works. Just click where you want to center on. Any star that has a box around it can be looked at (either solid box or broken box). Just click on it. Getting back to the galaxy is just scrolling back on the mouse until it pops you back. That's about it for now. Don't try to go to the "Exit To Main", it does nothing right now.

The fastest code is the code never written.

Attachments

Login to view attachments
Morcilla
21
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 26th Mar 2012 16:08
I'm not happy with mine. Transparent custom meshes, and the halo shader that comes with DarkShader, to make the edges invisible.

Not easy to achieve good results. Best thing would be to use some sort of voxels to represent the 3d shape, density, colors, etc. I think there was a code snippet related to voxels somewhere in the BDPro forum.

If you find a good technique please let us know

Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 26th Mar 2012 23:34
Halo shader..... Hum... I'm now using post bloom and it kinda looks ok. Could I use transparency with it?

The fastest code is the code never written.
Morcilla
21
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 27th Mar 2012 14:31
Yes I think so, and it doesn't stop you from using post bloom...
I recommend you to play around to judge the best approach/results.

Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 27th Mar 2012 14:37
I tried using the halo shader. It canceled out my transparency. I think that shader "out of the box" is not designed for transparency. I guess I could try to modify it, but I really don't know how...... I just don't know enough about shaders.

The fastest code is the code never written.
Morcilla
21
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 31st Mar 2012 18:52
Try dbGhostObjectOn along with the shader.

s_i
15
Years of Service
User Offline
Joined: 23rd May 2009
Location: Russia
Posted: 31st Mar 2012 21:51 Edited at: 31st Mar 2012 21:56
For my game I need nebulas too.
I attach three screenshots (in zip) from "Star Wars - Empire at War Forces of corruption" game for example. I think, nebulas on screenshots are semitransparent objects. Or 3-4 objects one in other (like russian "matryoshka"). You can use dbSetObjectTransparency for png-textures with transparent background, or dbGhostObjectOn for jpg-textures with black background. Good luck!
Like Morcilla sad, "If you find a good technique please let us know".
P.S. How did you maked so big (infinite) grid from little Grid.png?
--------------
Excuse me for bad English, please.

Attachments

Login to view attachments
Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 1st Apr 2012 15:35
Quote: "How did you maked so big (infinite) grid from little Grid.png?"

It's not exactly infinite. I made a 10x10 grid with the up and left run thicker and brighter than the others. Then I made a very large plane and textured it with the grid. I scaled the texture so that it looked right and *poof* it worked like a champ.

@Morcilla, I was actually using dbGhostObjectOn when I tried using the shader. I think I'll try something else today. I have a couple things in mind. I'll post something if I get different results.

The fastest code is the code never written.
Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 1st Apr 2012 17:41
Pic and download are in the first post. Here is the code for making the nebulae:
The first part is making the texture:

The PutCircleInMemBlock(..) part is something I made to put a circle in a memblock.
If you want the it, here it is:

Here is the SmoothMemblockImage(..) :

This is the part that makes the nebulae:


The fastest code is the code never written.
Morcilla
21
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 8th Apr 2012 12:56
Looking good and very interesting

Unfortunately I've not seen it in action. I tried to download using the 1st post link, but it tells me that the file 'Star Test demo.rar' is not found, uh

Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 8th Apr 2012 16:03 Edited at: 8th Apr 2012 17:08
That's strange. I can click on it and it comes up. I signed out of gmail, clicked on it, and it came up. I have the permissions correct.....

It actually says it's not found?

Just in case, here it is on this page:

It's actually more advanced than the other one, but you still have no multiplayer stuff. Just start a new singleplayer game and take a look. I've done some stuff with the stars so you can access them if you are close enough. This game will be similar to Master of Orion 2, so you will notice some similarities (including the "human" picture)

The fastest code is the code never written.

Attachments

Login to view attachments
Morcilla
21
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 15th Apr 2012 20:55
Hey thanks for updating the link.
I've checked them and well, they look pretty acceptable to me, very similar to what I did.
Good work, and very interesting image treatment with those memblock functions.
Keep on

Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 17th Apr 2012 01:28
Thanks.

The fastest code is the code never written.
WLGfx
17
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 23rd Apr 2012 03:20
I've just dropped by this Creating Nebulae and remembered this thread.

Mental arithmetic? Me? (That's for computers) I can't subtract a fart from a plate of beans!
Warning! May contain Nuts!
Hawkblood
14
Years of Service
User Offline
Joined: 5th Dec 2009
Location:
Posted: 23rd Apr 2012 23:51
Yea, that's the kind of thing I'm using.

The fastest code is the code never written.

Login to post a reply

Server time is: 2024-11-19 02:40:12
Your offset time is: 2024-11-19 02:40:12