Jump to content

Coronas For Stars - Josh?


Shard
 Share

Recommended Posts

Hey guys, I'm making a small simulation of a solar system and I'm making a star. I want the star to glow and have a corona but I can't seem to get it right. The corona seems to only stay inside and the star doesn't glow when I'm close to it. And the corona looks really bad up close.

 

Is there some way I can get this same result using lights and lighting effects?

 

Star.h

#pragma once
#include "Body.h"

class Star : public Body
{

public:

TLight starLight;
TCorona starCorona;

Star();
Star(float *mass, float *radius, string* name, TVec3 *pos)
{
	this->mass = (*mass);
	this->radius = (*radius);
	this->name = (*name);

	this->pos = (*pos);

	body = CreateBodySphere(this->radius);
	mesh = CreateSphere(20,body);

	int scale = (this->radius*2);
	ScaleMesh(mesh,Vec3(scale));


	//this->starLight = CreateDirectionalLight(mesh);
	this->starCorona = CreateCorona();

	PaintEntity(starCorona,LoadMaterial("abstract::flare1.mat"));

	SetCoronaRadius(starCorona,this->radius*5,this->radius*5);
	ScaleEntity(starCorona,Vec3(scale));

}
};

simpleSigPNG.png

 

Programmer/Engineer/Student

www.reikumar.com

 

2.6 GHz Intel Core Duo - nVidia GeForce 8600 GT - Windows 7 64-bit - 4 Gigs RAM

C++ - Visual Studio Express - Dark GDK - Leadwerks SDK

Link to comment
Share on other sites

So, no one?

 

Is there anything that you've implemented for this Josh?

simpleSigPNG.png

 

Programmer/Engineer/Student

www.reikumar.com

 

2.6 GHz Intel Core Duo - nVidia GeForce 8600 GT - Windows 7 64-bit - 4 Gigs RAM

C++ - Visual Studio Express - Dark GDK - Leadwerks SDK

Link to comment
Share on other sites

I am assuming you wish to have the corona visible when the player is far away from the star (ala E.V.E. Online) in which case I would simply recommend:

 

If DistanceToStar > 1AU

HideStar

 

That way the mesh of the star will no longer be blocking the corona.

 

I wouldn't know about glow though. That probably involves GLSL.

Link to comment
Share on other sites

I am assuming you wish to have the corona visible when the player is far away from the star (ala E.V.E. Online) in which case I would simply recommend:

 

If DistanceToStar > 1AU

HideStar

 

That way the mesh of the star will no longer be blocking the corona.

 

I wouldn't know about glow though. That probably involves GLSL.

 

 

Yes, I am trying to do it like Eve Online, where if your looking towards the star from very close, you see the corona and are basically blinded by it and at a distance it looks like a star. I don't want the star hidden, though. The problem that I'm having with it is making the star glow like it does in Eve instead of just the corona generated by Leadwerks.

simpleSigPNG.png

 

Programmer/Engineer/Student

www.reikumar.com

 

2.6 GHz Intel Core Duo - nVidia GeForce 8600 GT - Windows 7 64-bit - 4 Gigs RAM

C++ - Visual Studio Express - Dark GDK - Leadwerks SDK

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...