AmplifyCreations / AmplifyShaderEditor-Feedback

4 stars 0 forks source link

Implicit truncation of vector type warnings #359

Open LazyEti opened 1 day ago

LazyEti commented 1 day ago

Some nodes are generating Implicit truncation warning messages: image

Transform position: "anything" to Screen:

float3 worldToScreen279_g1368NDC = worldToScreen279_g1368/worldToScreen279_g1368.w; should become: float3 worldToScreen279_g1368NDC = worldToScreen279_g1368.xyz/worldToScreen279_g1368.w;

Grab Screen Color:

float4 fetchOpaqueVal2609 = float4( SHADERGRAPH_SAMPLE_SCENE_COLOR( ase_grabScreenPosNorm ), 1.0 ); should become: float4 fetchOpaqueVal2609 = float4( SHADERGRAPH_SAMPLE_SCENE_COLOR( ase_grabScreenPosNorm.xy ), 1.0 );

i think there might be more cases where this happens like transform direction View to Clip but I didn't bother writing them down when they appeared so more testing is probably in order to catch them all. the warnings are harmless but its just in the way

Dawie3565 commented 1 day ago

@LazyEti hello, thank you for the report to replicate we will need a bit more info including --- verify ASE version --- Verify Unity version --- Verify Unity Pipeline --- Verify what ASE templates used in ways to reproduce

LazyEti commented 1 day ago

@Dawie3565 ASE: 1.9.7.1 (latest) Unity: 2022.3.19f1 Pipeline: URP Template: Universal/(any)

Dawie3565 commented 1 day ago

added to 1.9.7.2 milestone

verified errors in: --- api 10.10.1 URP 2020.3.48 --- api 14.0.10 URP 2022.3.19 --- api 14.0.11 URP 2022.3.53 --- api 17.0.3 URP 6000.0.28

http://paste.amplify.pt/view/raw/222adb37 image

Dawie3565 commented 1 day ago

@diogovtx

for HDRP possible related or new Git ? same test but this returns breaking errors --- api 14.0.11 HDRP 2022.3.53

image