-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Show warning for GeometryInstance3D transparency in Mobile/Compatibility #87231
Show warning for GeometryInstance3D transparency in Mobile/Compatibility #87231
Conversation
This feature is currently only supported when using Forward+.
d038e3f
to
a9893e2
Compare
I'd like to see this in 4.3 please :) I ran into this yet again the other day (in the guise of fade distance). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be quite easy to add this to both renderers. The code can be mostly copy-pasted from the Forward+ renderer, but let's add this for now to avoid confusing people
Thanks! |
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This is mostly a copy-paste of similar changes in the Forward+ renderer, as hinted in godotengine#76774 (comment) and godotengine#87231 (review), along with a tweak to the shader and pipeline model. The shader pipeline tweak involves distinguishing geometry instance-enabled transparency from material-enabled transparency. A material cannot support transparency on a per-instance level; a separate pipeline must be used when rendering. Originally in c571e4a this was a non-trivial refactoring in Forward+ (which in the past few years has evolved a few more times to account for the multitude of combinations allowed there). I opted to follow a similar sentiment to `SceneShaderForwardClustered::PipelineColorPassFlags` in a simpler `SceneShaderForwardMobile::PipelinePasses` enum, which only accounts for don't-care or opaque pipelines vs. color transparency-enabled ones. This multiplies the number of `PipelineCacheRD`s by two, but otherwise accomplishes the goals without adding unnecessary changes or shooting myself or others in the foot (I hope). BTW I also reorganized and removed some redundant checks in `RenderForwardClustered::_geometry_instance_add_surface_with_material` (since I was comparing this side-by-side with the `RenderForwardMobile` version, which seems better-organized). There is no functional change since `has_alpha` is the only variable used and includes all the checks anyway.
This feature is currently only supported when using Forward+.