Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/FEmitter
Description
Tries to find a common type between A and B. The trivial case is when A and B are the same type, in which case that type is the common type. When A and B are primitive, the common type is defined as the type with the highest dimensions between the two and with a scalar kind that follows the progression: bool -> int -> float As an example, the common type between a float3 and a bool4 will be a float4. Note; that this may cause a loss of data when casting from int to float. It returns the common type if it exists, nullptr otherwise.
| Name | TryGetCommonType |
| Type | function |
| Header File | /Engine/Source/Runtime/Engine/Public/Materials/MaterialIREmitter.h |
| Include Path | #include "Materials/MaterialIREmitter.h" |
| Source | /Engine/Source/Runtime/Engine/Private/Materials/MaterialIREmitter.cpp |
FType TryGetCommonType
(
FType A,
FType B
)