3D [Solved] Display a Projection 100% Clearly Regardless of Fog/Light

Posho

Member
Hello, I've been fiddling with the 3D functions and I've stumbled into a doubt.

For certain reasons, I need to make certain projections on my 3D space always visible, clear, fully-colored regardless of any fog or lighting settings already applied with the d3d functions, just like the title says. And by this I'm not asking for just adding illumination or light spots. I genuinely require that some projections do fade with the fog and the distance and also having some that never blend with the fog.

Seems to me like an incredibly specific thing to ask, so is the question is, is it possible at all? :confused:

[Edit]
Here's a visual representation of what I'm looking for. I hope it's understandable.
 
Last edited:
L

LazyEpic

Guest
How are you applying the fog? by fog do you just mean fade out distance "fog"?
In theory you should just not apply those shaders/transformations etc on those specific objects when you draw them and they should render the same no matter what?
 
A

Azure Spectre

Guest
I assume you are using the built in d3d_set_fog?

You can turn off the fog before drawing those objects, then turn it back on when you are done.
 

Posho

Member
I edited the opening post by adding an image representation of what I'm looking for, hope it helps.

How are you applying the fog? by fog do you just mean fade out distance "fog"?
In theory you should just not apply those shaders/transformations etc on those specific objects when you draw them and they should render the same no matter what?
By fog I mean the average d3d_set_fog GML function.
How exactly can I not apply the shaders to the objects? The only active shader is in the camera object's Draw event as d3d_set_fog.

I assume you are using the built in d3d_set_fog?

You can turn off the fog before drawing those objects, then turn it back on when you are done.
How? The only active shader is in the camera object's Draw event as d3d_set_fog.
How can I do that?
 
are you using shaders as in one from your resrouce tree under the "shaders" folder?

if you want some things to draw with fog and other things to draw without fog,
turn fog on, draw everything that you want to have fog,
turn fog off, draw everything that you want to not have fog.
 

Posho

Member
are you using shaders as in one from your resrouce tree under the "shaders" folder?

if you want some things to draw with fog and other things to draw without fog,
turn fog on, draw everything that you want to have fog,
turn fog off, draw everything that you want to not have fog.
I just wrote d3d_set_fog(0,0,0,0) at the beginning of the Draw event of whatever instance I want to ignore the fog. That does the job, actually. o_O

Thanks a ton, man.
 

Posho

Member
I just wrote d3d_set_fog(0,0,0,0) at the beginning of the Draw event of whatever instance I want to ignore the fog. That does the job, actually.
Just in case someone actually reads this thread in the future:
Remember to turn on your fog/shaders again, or else it'll screw your game up.
 
Top