• R/O
  • HTTP
  • SSH
  • HTTPS

提交

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

wwww


Commit MetaInfo

修訂d6aa8de1065d2657d9aebc1d7fc9953588675e25 (tree)
時間2016-05-09 15:39:14
作者sparky4 <sparky4@cock...>
Commitersparky4

Log Message

wwww

Change Summary

差異

Binary files a/pcx2vrl and b/pcx2vrl differ
Binary files a/pcxsscut and b/pcxsscut differ
--- a/src/lib/modex16.c
+++ b/src/lib/modex16.c
@@ -187,6 +187,7 @@ modexDefaultPage(page_t *p)
187187 page.tilesh=page.height/TILEWH;
188188 page.tilemidposscreenx = page.tw/2;
189189 page.tilemidposscreeny = (page.th/2)+1;
190+ page.stridew=page.width/4;
190191 page.pagesize = (sdiword)(page.width/4)*page.height;
191192 page.id = 0;
192193
@@ -212,6 +213,7 @@ modexNextPage(page_t *p) {
212213 result.tilesw = p->tilesw;
213214 result.tilesh = p->tilesh;
214215 result.id = p->id+1;
216+ result.stridew=p->stridew;
215217 result.pagesize = p->pagesize;
216218
217219 return result;
@@ -235,6 +237,7 @@ modexNextPageFlexibleSize(page_t *p, word x, word y)
235237 result.tilesw=result.width/TILEWH;
236238 result.tilesh=result.height/TILEWH;
237239 result.id = p->id+1;
240+ result.stridew=result.width/4;
238241 result.pagesize = (sdiword)(result.width/4)*result.height;
239242
240243 return result;
@@ -315,8 +318,8 @@ modexClearRegion(page_t *page, int x, int y, int w, int h, byte color) {
315318 word pageOff = (word) page->data;
316319 word xoff=x/4; /* xoffset that begins each row */
317320 word scanCount=w/4; /* number of iterations per row (excluding right clip)*/
318- word poffset = pageOff + y*(page->width/4) + xoff; /* starting offset */
319- word nextRow = page->width/4-scanCount-1; /* loc of next row */
321+ word poffset = pageOff + y*(page->stridew) + xoff; /* starting offset */
322+ word nextRow = page->stridew-scanCount-1; /* loc of next row */
320323 byte lclip[] = {0x0f, 0x0e, 0x0c, 0x08}; /* clips for rectangles not on 4s */
321324 byte rclip[] = {0x00, 0x01, 0x03, 0x07};
322325 byte left = lclip[x&0x03];
@@ -392,11 +395,11 @@ modexCopyPageRegion(page_t *dest, page_t *src,
392395 word dx, word dy,
393396 word width, word height)
394397 {
395- word doffset = (word)dest->data + dy*(dest->width/4) + dx/4;
396- word soffset = (word)src->data + sy*(src->width/4) + sx/4;
398+ word doffset = (word)dest->data + dy*(dest->stridew) + dx/4;
399+ word soffset = (word)src->data + sy*(src->stridew) + sx/4;
397400 word scans = vga_state.vga_stride;
398- word nextSrcRow = src->width/4 - scans - 1;
399- word nextDestRow = dest->width/4 - scans - 1;
401+ word nextSrcRow = src->stridew - scans - 1;
402+ word nextDestRow = dest->stridew - scans - 1;
400403 byte lclip[] = {0x0f, 0x0e, 0x0c, 0x08}; /* clips for rectangles not on 4s */
401404 byte rclip[] = {0x0f, 0x01, 0x03, 0x07};
402405 byte left = lclip[sx&0x03];
--- a/src/lib/typdefst.h
+++ b/src/lib/typdefst.h
@@ -82,6 +82,7 @@ typedef struct {
8282 sword tilemidposscreeny; /* middle tile position */
8383 sword tileplayerposscreenx; /* player position on screen */
8484 sword tileplayerposscreeny; /* player position on screen */
85+ word stridew; /*width/4*/
8586 sdiword pagesize; /* page size */
8687 } page_t;
8788
Binary files a/vrl2vrs and b/vrl2vrs differ
Binary files a/vrsdump and b/vrsdump differ