mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-09-05 00:56:13 +00:00
BBox: Changed the rounding again, the old one fixed Paper Mario but had bugs in Mickey's Magical Mirror. This change fixes the glitches in both games.
Also fixed some compiler warnings.
This commit is contained in:
parent
d3fd0eddbb
commit
9b6c6fa9e4
12 changed files with 16 additions and 16 deletions
|
@ -34,7 +34,7 @@ namespace DriverDetails
|
|||
|
||||
Vendor m_vendor = VENDOR_UNKNOWN;
|
||||
Driver m_driver = DRIVER_UNKNOWN;
|
||||
s32 m_family = 0.0;
|
||||
s32 m_family = 0;
|
||||
double m_version = 0.0;
|
||||
|
||||
// This is a list of all known bugs for each vendor
|
||||
|
|
|
@ -15,7 +15,7 @@ struct XFBSourceBase
|
|||
{
|
||||
virtual ~XFBSourceBase() {}
|
||||
|
||||
virtual void Draw(const MathUtil::Rectangle<float> &sourcerc,
|
||||
virtual void Draw(const MathUtil::Rectangle<int> &sourcerc,
|
||||
const MathUtil::Rectangle<float> &drawrc) const = 0;
|
||||
|
||||
virtual void DecodeToTexture(u32 xfbAddr, u32 fbWidth, u32 fbHeight) = 0;
|
||||
|
|
|
@ -254,8 +254,8 @@ void LOADERDECL UpdateBoundingBox()
|
|||
}
|
||||
|
||||
// Convert to screen space and add the point to the list - round like the real hardware
|
||||
s_bbox_points[s_bbox_currPoint].x = (((s32) (0.5f + (16.0f * (screenPoint[0] * xfregs.viewport.wd + (xfregs.viewport.xOrig - 342.0f))))) - 9) >> 4;
|
||||
s_bbox_points[s_bbox_currPoint].y = (((s32) (0.5f + (16.0f * (screenPoint[1] * xfregs.viewport.ht + (xfregs.viewport.yOrig - 342.0f))))) - 9) >> 4;
|
||||
s_bbox_points[s_bbox_currPoint].x = (((s32) (0.5f + (16.0f * (screenPoint[0] * xfregs.viewport.wd + (xfregs.viewport.xOrig - 342.0f))))) + 3) >> 4;
|
||||
s_bbox_points[s_bbox_currPoint].y = (((s32) (0.5f + (16.0f * (screenPoint[1] * xfregs.viewport.ht + (xfregs.viewport.yOrig - 342.0f))))) + 3) >> 4;
|
||||
s_bbox_points[s_bbox_currPoint].z = screenPoint[2];
|
||||
|
||||
// Update point list for primitive
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue