video_core: Silence implicit conversion warnings
This commit is contained in:
parent
fa0d65fc7b
commit
096f339a2a
9 changed files with 62 additions and 53 deletions
|
@ -342,13 +342,14 @@ struct TSCEntry {
|
|||
float GetLodBias() const {
|
||||
// Sign extend the 13-bit value.
|
||||
constexpr u32 mask = 1U << (13 - 1);
|
||||
return static_cast<s32>((mip_lod_bias ^ mask) - mask) / 256.0f;
|
||||
return static_cast<float>(static_cast<s32>((mip_lod_bias ^ mask) - mask)) / 256.0f;
|
||||
}
|
||||
|
||||
std::array<float, 4> GetBorderColor() const {
|
||||
if (srgb_conversion) {
|
||||
return {srgb_border_color_r / 255.0f, srgb_border_color_g / 255.0f,
|
||||
srgb_border_color_b / 255.0f, border_color[3]};
|
||||
return {static_cast<float>(srgb_border_color_r) / 255.0f,
|
||||
static_cast<float>(srgb_border_color_g) / 255.0f,
|
||||
static_cast<float>(srgb_border_color_b) / 255.0f, border_color[3]};
|
||||
}
|
||||
return border_color;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue