The FSceneView::Deproject function calls FMatrix::TransformVector4 and passes an FPlane value. TransformVector4 takes in an FVector4 parameter, so the value being passed is implicitly converted to FVector4. However, the conversion process first converts the FPlane to FVector, and then converts the FVector to FVector4. In this process, the W component of the original FPlane is lost.
It may be better to either create and pass an FVector4 value in this case (so no implicit conversion is needed), or to make FPlane(const FVector4&) explicit.
RESULT:
In the call to TransformFVector4, an FPlane is created and passed to the function. TransformFVector4 takes an FVector4 parameter, so this call results in an implicit conversion from FPlane to FVector to FVector4, and the W component of the FPlane is lost.
EXPECTED:
The W component is correctly included in the parameter received by the TransformFVector4 function.
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-53721 in the post.
2 |
Component | UE - Foundation - Core |
---|---|
Affects Versions | 4.16.3, 4.17.2, 4.20 |
Created | Jan 3, 2018 |
---|---|
Resolved | Aug 18, 2021 |
Updated | Aug 18, 2021 |