DXGL r861 - Code Review
For
DXGL
(
recent comments
|
status changes
|
tags
|
authors
|
states
|
release notes
|
statistics
)
Jump to navigation
Jump to search
Repository:
DXGL
Revision:
<
r860
|
r861
|
r862
>
Date:
14:44, 9 September 2018
Author:
admin
Status:
new
Tags:
Comment:
Revert
r856
of glRenderer.cpp
Modified paths:
/ddraw/glRenderer.cpp
(modified) (
history
)
Diff
[
purge
]
Index: ddraw/glRenderer.cpp
—
—
@@ -3412,33 +3412,25 @@
3413
3413
{
3414
3414
ddsdSrc = cmd->src->levels[cmd->srclevel].ddsd;
3415
3415
if (cmd->src->levels[cmd->srclevel].dirty & 1) glTexture__Upload(cmd->src, cmd->srclevel);
3416
- if (!memcmp(&cmd->srcrect, &nullrect, sizeof(RECT)))
3417
- {
3418
- srcrect.left = 0;
3419
- srcrect.top = 0;
3420
- srcrect.right = ddsdSrc.dwWidth;
3421
- srcrect.bottom = ddsdSrc.dwHeight;
3422
- }
3423
3416
}
3424
3417
if (cmd->dest->levels[cmd->destlevel].dirty & 1)
3425
3418
glTexture__Upload(cmd->dest, cmd->destlevel);
3419
+ if (!memcmp(&cmd->srcrect, &nullrect, sizeof(RECT)))
3420
+ {
3421
+ srcrect.left = 0;
3422
+ srcrect.top = 0;
3423
+ srcrect.right = ddsdSrc.dwWidth;
3424
+ srcrect.bottom = ddsdSrc.dwHeight;
3425
+ }
3426
3426
else srcrect = cmd->srcrect;
3427
3427
This->bltvertices[1].x = This->bltvertices[3].x = (GLfloat)destrect.left;
3428
3428
This->bltvertices[0].x = This->bltvertices[2].x = (GLfloat)destrect.right;
3429
3429
This->bltvertices[0].y = This->bltvertices[1].y = (GLfloat)ddsd.dwHeight - (GLfloat)destrect.top;
3430
3430
This->bltvertices[2].y = This->bltvertices[3].y = (GLfloat)ddsd.dwHeight - (GLfloat)destrect.bottom;
3431
- if (cmd->src)
3432
- {
3433
- This->bltvertices[1].s = This->bltvertices[3].s = (GLfloat)srcrect.left / (GLfloat)ddsdSrc.dwWidth;
3434
- This->bltvertices[0].s = This->bltvertices[2].s = (GLfloat)srcrect.right / (GLfloat)ddsdSrc.dwWidth;
3435
- This->bltvertices[0].t = This->bltvertices[1].t = (GLfloat)srcrect.top / (GLfloat)ddsdSrc.dwHeight;
3436
- This->bltvertices[2].t = This->bltvertices[3].t = (GLfloat)srcrect.bottom / (GLfloat)ddsdSrc.dwHeight;
3437
- }
3438
- else
3439
- {
3440
- This->bltvertices[1].s = This->bltvertices[3].s = This->bltvertices[0].t = This->bltvertices[1].t = 0.0f;
3441
- This->bltvertices[0].s = This->bltvertices[2].s = This->bltvertices[2].t = This->bltvertices[3].t = 1.0f;
3442
- }
3431
+ This->bltvertices[1].s = This->bltvertices[3].s = (GLfloat)srcrect.left / (GLfloat)ddsdSrc.dwWidth;
3432
+ This->bltvertices[0].s = This->bltvertices[2].s = (GLfloat)srcrect.right / (GLfloat)ddsdSrc.dwWidth;
3433
+ This->bltvertices[0].t = This->bltvertices[1].t = (GLfloat)srcrect.top / (GLfloat)ddsdSrc.dwHeight;
3434
+ This->bltvertices[2].t = This->bltvertices[3].t = (GLfloat)srcrect.bottom / (GLfloat)ddsdSrc.dwHeight;
3443
3435
if ((cmd->bltfx.dwSize == sizeof(DDBLTFX)) && (cmd->flags & DDBLT_DDFX))
3444
3436
{
3445
3437
if (cmd->bltfx.dwDDFX & DDBLTFX_MIRRORLEFTRIGHT)
Past revisions this follows-up on
Revision
Commit summary
Author
Date
r856
Set version to 0.5.16 pre-release...
admin
00:20, 6 September 2018
Navigation menu
Personal tools
Log in
Namespaces
Special page
English
expanded
collapsed
Views
More
expanded
collapsed
Search
Navigation
Home
Main page
Recent changes
Random page
MediaWiki help
Introduction
Progress
Downloads
Source code
Build from source
AppDB
Bug reports
Forums
Tools
Special pages
Printable version