/* Project 16 Source Code~\r
- * Copyright (C) 2012-2016 sparky4 & pngwen & andrius4669\r
+ * Copyright (C) 2012-2016 sparky4 & pngwen & andrius4669 & joncampbell123 & yakui-lover\r
*\r
* This file is part of Project 16.\r
*\r
* Project 16 is free software; you can redistribute it and/or modify\r
* it under the terms of the GNU General Public License as published by\r
- * the Free Software Foundation; either verson 3 of the License, or\r
+ * the Free Software Foundation; either version 3 of the License, or\r
* (at your option) any later version.\r
*\r
* Project 16 is distributed in the hope that it will be useful,\r
page.tilemidposscreenx = page.tw/2;\r
page.tilemidposscreeny = (page.th/2)+1;\r
page.stridew=page.width/4;\r
- page.pagesize = (word)(page.width/4)*page.height;\r
- page.pi=4;\r
+ page.pagesize = (word)(page.stridew)*page.height;\r
+ page.pi=page.width*4;\r
page.id = 0;\r
\r
return page;\r
result.tilesh = p->tilesh;\r
result.stridew=p->stridew;\r
result.pagesize = p->pagesize;\r
- result.pi=4;\r
+ result.pi=result.width*4;\r
result.id = p->id+1;\r
\r
return result;\r
result.tilesw=result.width/TILEWH;\r
result.tilesh=result.height/TILEWH;\r
result.id = p->id+1;\r
- result.stridew=result.width/4;\r
- result.pagesize = (word)(result.width/4)*result.height;\r
- if(result.id==2)\r
- result.pi=p->width*p->pi;\r
- else if(result.id==3) result.pi=p->pi;\r
+ result.stridew=p->sw/4;//result.width/4;\r
+ result.pagesize = (word)(result.stridew)*result.height;\r
+ switch(result.id)\r
+ {\r
+ case 2:\r
+ result.pi=p->width*4;\r
+ break;\r
+ case 3:\r
+ result.pi=p->pi;\r
+ break;\r
+ }\r
\r
return result;\r
}\r
{\r
word doffset = (word)dest->data + dy*(dest->stridew) + dx/4;\r
word soffset = (word)src->data + sy*(src->stridew) + sx/4;\r
- word scans = vga_state.vga_stride+8; //++++0000 the quick and dirty fix of the major issue with p16 video display wwww\r
+ word scans = vga_state.vga_stride; //++++0000 the quick and dirty fix of the major issue with p16 video display wwww\r
word nextSrcRow = src->stridew - scans - 1;\r
word nextDestRow = dest->stridew - scans - 1;\r
byte lclip[] = {0x0f, 0x0e, 0x0c, 0x08}; /* clips for rectangles not on 4s */\r