MonoGame icon indicating copy to clipboard operation
MonoGame copied to clipboard

Is spriteBatch.Begin(effect: normalEffect) not supported?

Open MCVenor opened this issue 1 year ago • 0 comments

Prerequisites

  • [X] I have verified this issue is present in the develop branch
  • [X] I have searched open and closed issues to ensure it has not already been reported.

MonoGame Version

MonoGame ComputeShader 3.8.3

Which MonoGame platform are you using?

MonoGame Cross-Platform Desktop Application (mgdesktopgl)

Operating System

Windows

Description

Hi,

first sorry, i have not checked the develop branch, i just downloaded the nugget package as described on this repo.

I was hitting a wall when i tried to make the this fork work in my project for the last 2-3 days. Thinking that something in my project just didnt work.

so i tried the following:

  • Download the Sample https://github.com/cpt-max/MonoGame-Shader-Samples/tree/compute_write_to_texture
  • Create a new Effect with the MGCB inside that sample
  • give spriteBatch.Begin the created and loaded Effect, like so spriteBatch.Begin(effect: normalEffect);
  • the Texture turn black

so my question is, is the usage of spriteBatch.Begin not allowed ? I could work with that limitation but i could not find any information about this.

Note: With some testing i think the textureCoordinates are all 0 in the shaders, but im way too new to this shader stuff to be certain.

Steps to Reproduce

  • Download the Sample https://github.com/cpt-max/MonoGame-Shader-Samples/tree/compute_write_to_texture
  • Create a new Effect with the MGCB inside that sample
  • give spriteBatch.Begin the created and loaded Effect, like so spriteBatch.Begin(effect: normalEffect);

Minimal Example Repo

No response

Expected Behavior

i expected shaders to work in a stacking manner.

Resulting Behavior

Texture no longer renders properly.

Files

No response

MCVenor avatar Nov 03 '24 11:11 MCVenor