stride3d / stride3d/stride

[Rendering] Mult blending causes crash

Open
#584 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area-Graphics bug
Dominant language
C#
Stars
7.8k
Forks
1.2k
Avg merge
2d 17h
Merged PRs (30d)
49

Description

Release Type: GitHub

Version: Latest as of the time of writing

Platform(s): Windows DirectX 11

Describe the bug
Setting a pass's BlendState to an illegal state based on the transparency toggle of that pass crashes the application.

To Reproduce
Steps to reproduce the behavior:

  1. Get a reference to material.
  2. Set transparency through TargetMaterial.Passes[ 0 ].HasTransparency = true;
  3. Run this TargetMaterial.Passes[ 0 ].BlendState = new BlendStateDescription( Blend.DestinationColor, Blend.Zero );

Expected behavior
Blends multiplicatively or throws a clearer exception.

Log and callstacks
Stack

Additional context
None.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the crash with the BlendState and HasTransparency settings in the issue, then inspect the attached MultCrash.txt stack trace and the rendering blend-state handling it identifies. Done means the illegal combination no longer crashes silently: it either produces multiplicative blending or raises a clearer exception, as specified by the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
computer-graphics, game-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.