Jump to content
  • Advertisement
Sign in to follow this  
Migi0027

DX11 DX11 - Dominant Textures

This topic is 2140 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi guys! wink.png

 

I'm having a small problem here, that I would like to get fixed, as I'm on a kind of a bug fixing period.

 

Screenshot.

ampl3o.png

 

 

If you look closely you can see some icons, I call them the debug helpers. To blend them into the scene (They have a separate pass), I simply add the color in the post processing shader, but, then it doesn't come as I hoped, as the colors blend together, kinda obvious biggrin.png .

 

So. Now I ask you, how can this be made, without the blending of colors, so if a sprite (it's sprites) is blackish, it becomes black!

 

What I could do is to, after all the draw calls, draw these special helpers with depth testing disabled.

 

But are there other ways?

 

Thanks, as usual!

-MIGI0027

Share this post


Link to post
Share on other sites
Advertisement
This looks like additive blending and it sounds like you want alpha blending (copied from a SDK sample)

    D3D11_BLEND_DESC dsc = 
    {
        false,//BOOL AlphaToCoverageEnable;
        false,//BOOL IndependentBlendEnable;
        {
        true, //BOOL BlendEnable;
        D3D11_BLEND_SRC_ALPHA, //D3D11_BLEND SrcBlend;
        D3D11_BLEND_INV_SRC_ALPHA ,    //D3D11_BLEND DestBlend;
        D3D11_BLEND_OP_ADD,    //D3D11_BLEND_OP BlendOp;
        D3D11_BLEND_ZERO ,    //D3D11_BLEND SrcBlendAlpha;
        D3D11_BLEND_ZERO ,    //D3D11_BLEND DestBlendAlpha;
        D3D11_BLEND_OP_ADD,    //D3D11_BLEND_OP BlendOpAlpha;
        D3D11_COLOR_WRITE_ENABLE_ALL //UINT8 RenderTargetWriteMask;    
        } 
    };
Your sprite textures need a proper alpha channel for this. Also: Google for the difference between premultiplied and non-premultiplied alpha blending (the above code is the latter).

Share this post


Link to post
Share on other sites

Its all about the moves and the complexity of them

I hate to see that people continue the model of click this text and then this text and then this text to do something

Its slow in the sense of making an action and in learning how to use the program

If the computer was my body, I will have to make some silly 100 different clicks in different places to make my body take an object from the floor

so when you develop a program think more about how is that input made, and make it cooler, we must change that silly model of clicking this text then this text and then this other text.......

Share this post


Link to post
Share on other sites

I prefer now that you know that, develop it alone and then we will see what new things you can create

 

Every program should have too a kind of visual start that makes us do all the things that can be done with the program

In the proces makes us learn all those cool moves and conbinations to get the program do something

that should not be teached by other person, or a book

Edited by lomateron

Share this post


Link to post
Share on other sites

Thanks for the support unbird, appreciate it. wink.png

You're welcome.

 

And yeah, I expect an intuitive and convenient interface for something as complex as a game/3D editor to be quite hard to do. It's a nice start you got there, so congrats.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!