亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? sprite.java

?? 這是j2me里MIDP2.0中game包的源代碼
?? JAVA
?? 第 1 頁 / 共 5 頁
字號:
	int xIncr1, yIncr1;	// .. for image 2	int startY2;	int xIncr2, yIncr2;	int numPixels = height * width;	int[] argbData1 = new int[numPixels];	int[] argbData2 = new int[numPixels];	if (0x0 != (transform1 & INVERTED_AXES)) {	    // inverted axes	    // scanlength = height	    if (0x0 != (transform1 & Y_FLIP)) {		xIncr1 = -(height); // - scanlength		startY1 = numPixels - height; // numPixels - scanlength	    } else {		xIncr1 = height; // + scanlength				startY1 = 0;	    }	    if (0x0 != (transform1 &  X_FLIP)) {		yIncr1 = -1;		startY1 += (height - 1);	    } else {		yIncr1 = +1;	    }	    image1.getRGB(argbData1, 0, height, // scanlength = height			  image1XOffset, image1YOffset, height, width);	} else {	    // scanlength = width	    if (0x0 != (transform1 & Y_FLIP)) {		startY1 = numPixels - width; // numPixels - scanlength		yIncr1  = -(width); // - scanlength	    } else {		startY1 = 0;		yIncr1  = width; // + scanlength	    }	    if (0x0 != (transform1 &  X_FLIP)) {		xIncr1  = -1;		startY1 += (width - 1);	    } else {		xIncr1  = +1;	    }	    image1.getRGB(argbData1, 0, width, // scanlength = width			  image1XOffset, image1YOffset, width, height);	}	if (0x0 != (transform2 & INVERTED_AXES)) {	    // inverted axes	    if (0x0 != (transform2 & Y_FLIP)) {		xIncr2 = -(height);		startY2 = numPixels - height;	    } else {		xIncr2 = height;		startY2 = 0;	    }	    if (0x0 != (transform2 &  X_FLIP)) {		yIncr2 = -1;				startY2 += height - 1;	    } else {		yIncr2 = +1;	    }	    image2.getRGB(argbData2, 0, height,			  image2XOffset, image2YOffset, height, width);	} else {	    if (0x0 != (transform2 & Y_FLIP)) {		startY2 = numPixels - width;		yIncr2  = -(width);	    } else {		startY2 = 0;		yIncr2  = +width;	    }	    if (0x0 != (transform2 &  X_FLIP)) {		xIncr2  = -1;		startY2 += (width - 1);	    } else {		xIncr2  = +1;	    }	    image2.getRGB(argbData2, 0, width,			  image2XOffset, image2YOffset, width, height);	}	int x1, x2;	int xLocalBegin1, xLocalBegin2;	// the loop counters	int numIterRows;	int numIterColumns;	for (numIterRows = 0, xLocalBegin1 = startY1, xLocalBegin2 = startY2;	    numIterRows < height;	    xLocalBegin1 += yIncr1, xLocalBegin2 += yIncr2, numIterRows++) {	    for (numIterColumns = 0, x1 = xLocalBegin1, x2 = xLocalBegin2;		 numIterColumns < width;		 x1 += xIncr1, x2 += xIncr2, numIterColumns++) {		if (((argbData1[x1] & ALPHA_BITMASK) != 0) && 		    ((argbData2[x2] & ALPHA_BITMASK) != 0)) {		    return true;		}			    } // end for x		    	} // end for y		// worst case!  couldn't find a single colliding pixel!	return false;    }    /**     * Given a rectangle that lies within the sprite      * in the painter's coordinates,     * find the X coordinate of the top left corner      * in the source image of the sprite     *     * @param x1 the x coordinate of the top left of the rectangle     * @param y1 the y coordinate of the top left of the rectangle     * @param x2 the x coordinate of the bottom right of the rectangle     * @param y2 the y coordinate of the bottom right of the rectangle     *      * @return the X coordinate in the source image     *      */    private int getImageTopLeftX(int x1, int y1, int x2, int y2) {	int retX = 0;	// left = this.x	// right = this.x + this.width	// top = this.y	// bottom = this.y + this.height	switch (this.t_currentTransformation) {	case TRANS_NONE:	case TRANS_MIRROR_ROT180:	    retX = x1 - this.x;	    break;	case TRANS_MIRROR:	case TRANS_ROT180:	    retX = (this.x + this.width) - x2;	    break;	case TRANS_ROT90:	case TRANS_MIRROR_ROT270:	    retX = y1 - this.y;	    break;	case TRANS_ROT270:	case TRANS_MIRROR_ROT90:	    retX = (this.y + this.height) - y2;	    break;	}	retX += frameCoordsX[frameSequence[sequenceIndex]];	return retX;    }    /**     * Given a rectangle that lies within the sprite      * in the painter's coordinates,     * find the Y coordinate of the top left corner      * in the source image of the sprite     *     * @param x1 the x coordinate of the top left of the rectangle     * @param y1 the y coordinate of the top left of the rectangle     * @param x2 the x coordinate of the bottom right of the rectangle     * @param y2 the y coordinate of the bottom right of the rectangle     *      * @return the Y coordinate in the source image     *      */    private int getImageTopLeftY(int x1, int y1, int x2, int y2) {	int retY = 0;	// left = this.x	// right = this.x + this.width	// top = this.y	// bottom = this.y + this.height	switch (this.t_currentTransformation) {	case TRANS_NONE:	case TRANS_MIRROR:	    retY = y1 - this.y;	    break;	case TRANS_ROT180:	case TRANS_MIRROR_ROT180:	    retY = (this.y + this.height) - y2;	    break;	case TRANS_ROT270:	case TRANS_MIRROR_ROT270:	    retY = x1 - this.x;	    break;	case TRANS_ROT90:	case TRANS_MIRROR_ROT90:	    retY = (this.x + this.width) - x2;	    break;	}	retY += frameCoordsY[frameSequence[sequenceIndex]];	return retY;    }    /**     * Sets the transform for this Sprite     *     * @param transform the desired transform for this Sprite     */    private void setTransformImpl(int transform) {	// ---	// setTransform sets up all transformation related data structures	// except transforming the current frame's bitmap.		// x, y, width, height, dRefX, dRefY, 	// collisionRectX, collisionRectY, collisionRectWidth,	// collisionRectHeight, t_currentTransformation,	// t_bufferImage	// The actual tranformed frame is drawn at paint time.	// ---	// update top-left corner position	this.x = this.x + 	    getTransformedPtX(dRefX, dRefY, this.t_currentTransformation) -	    getTransformedPtX(dRefX, dRefY, transform);	this.y = this.y +	    getTransformedPtY(dRefX, dRefY, this.t_currentTransformation) -	    getTransformedPtY(dRefX, dRefY, transform);	// Calculate transformed sprites collision rectangle	// and transformed width and height	computeTransformedBounds(transform);	// set the current transform to be the one requested	t_currentTransformation = transform;    }    /**     * Calculate transformed sprites collision rectangle     * and transformed width and height     * @param transform the desired transform for this <code>Sprite</code>     */    private void computeTransformedBounds(int transform) {	switch (transform) {	case TRANS_NONE:	    t_collisionRectX = collisionRectX;	    t_collisionRectY = collisionRectY;	    t_collisionRectWidth = collisionRectWidth;	    t_collisionRectHeight = collisionRectHeight;  	    this.width = srcFrameWidth;  	    this.height = srcFrameHeight;	    break;	case TRANS_MIRROR:	    // flip across vertical	    // NOTE: top left x and y coordinate must reflect the transformation	    // performed around the reference point	    // the X-offset of the reference point from the top left corner	    // changes.	    t_collisionRectX = srcFrameWidth - 		               (collisionRectX + collisionRectWidth);	    t_collisionRectY = collisionRectY;	    t_collisionRectWidth = collisionRectWidth;	    t_collisionRectHeight = collisionRectHeight;	    // the Y-offset of the reference point from the top left corner	    // remains the same,	    // top left X-co-ordinate changes  	    this.width = srcFrameWidth;  	    this.height = srcFrameHeight;	    break;	case TRANS_MIRROR_ROT180:	    // flip across horizontal	    // NOTE: top left x and y coordinate must reflect the transformation	    // performed around the reference point	    // the Y-offset of the reference point from the top left corner	    // changes	    t_collisionRectY = srcFrameHeight -                                (collisionRectY + collisionRectHeight);	    t_collisionRectX = collisionRectX;	    t_collisionRectWidth = collisionRectWidth;	    t_collisionRectHeight = collisionRectHeight;	    // width and height are as before  	    this.width = srcFrameWidth;  	    this.height = srcFrameHeight;    	    // the X-offset of the reference point from the top left corner	    // remains the same.	    // top left Y-co-ordinate changes	    	    break;	case TRANS_ROT90:	    // NOTE: top left x and y coordinate must reflect the transformation	    // performed around the reference point	    // the bottom-left corner of the rectangle becomes the 	    // top-left when rotated 90.	    // both X- and Y-offset to the top left corner may change	    // update the position information for the collision rectangle	    t_collisionRectX = srcFrameHeight -                                (collisionRectHeight + collisionRectY);	    t_collisionRectY = collisionRectX;	    t_collisionRectHeight = collisionRectWidth;	    t_collisionRectWidth 

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
91色九色蝌蚪| 26uuu亚洲综合色欧美| 69av一区二区三区| 国产网红主播福利一区二区| 一级精品视频在线观看宜春院| 美日韩黄色大片| 色婷婷精品久久二区二区蜜臀av| 欧美精品一区二区精品网| 亚洲图片有声小说| 91原创在线视频| 国产欧美在线观看一区| 久久99精品久久久久| 91精品办公室少妇高潮对白| 欧美国产国产综合| 国产中文一区二区三区| 91精品国产综合久久精品图片| 亚洲免费视频成人| 高清在线成人网| 久久久久久9999| 国模少妇一区二区三区| 欧美色偷偷大香| 一区二区不卡在线视频 午夜欧美不卡在| 国产成人精品亚洲日本在线桃色| 日韩欧美一区二区不卡| 日韩在线一区二区| 欧美日韩亚洲不卡| 亚洲丰满少妇videoshd| 在线观看三级视频欧美| 依依成人精品视频| 日本韩国视频一区二区| 亚洲色图在线播放| 91理论电影在线观看| 亚洲视频1区2区| 在线区一区二视频| 亚洲福利一二三区| 日韩欧美一卡二卡| 国产中文字幕一区| 国产精品福利在线播放| 91女人视频在线观看| 亚洲精品亚洲人成人网| 欧美日韩专区在线| 天堂精品中文字幕在线| 日韩精品在线一区二区| 韩国在线一区二区| 国产精品污污网站在线观看| 91网址在线看| 午夜影院久久久| 欧美videossexotv100| 麻豆精品在线看| 777a∨成人精品桃花网| 国产尤物一区二区| 一区二区中文字幕在线| 欧美日韩一级黄| 男人的天堂久久精品| 中文字幕+乱码+中文字幕一区| 色婷婷综合久久久中文一区二区| 婷婷开心激情综合| 国产丝袜美腿一区二区三区| 色综合网色综合| 免费高清不卡av| 国产精品久久久久婷婷| 欧美日韩aaa| 国产很黄免费观看久久| 亚洲一区二区三区四区在线观看 | 欧美不卡一区二区| 岛国一区二区三区| 亚洲午夜国产一区99re久久| 精品精品国产高清a毛片牛牛| av不卡免费在线观看| 青青国产91久久久久久| 国产精品欧美久久久久一区二区| 91在线看国产| 黄页视频在线91| 亚洲一二三区视频在线观看| wwww国产精品欧美| 欧美日韩精品一区二区天天拍小说 | 精品中文av资源站在线观看| 日韩一区在线免费观看| 欧美一卡二卡在线| 在线视频欧美精品| 国产精品91一区二区| 午夜精品久久久久久久久久久| 久久久无码精品亚洲日韩按摩| 欧美四级电影在线观看| 成人av手机在线观看| 午夜国产精品影院在线观看| 日本一区二区成人在线| 26uuu精品一区二区三区四区在线| 在线视频综合导航| 色呦呦国产精品| 丰满亚洲少妇av| 黄色成人免费在线| 日本伊人午夜精品| 亚洲精品欧美专区| 国产精品久久看| 日韩欧美一区中文| 欧美日韩三级在线| 欧美在线短视频| 99久久99久久精品免费看蜜桃| 狠狠色综合播放一区二区| 麻豆精品视频在线观看视频| 亚洲精品国产精品乱码不99| 国产日本一区二区| 欧美激情一区不卡| 国产日韩欧美不卡在线| 国产日本一区二区| 国产精品女同一区二区三区| 国产三级精品三级在线专区| 精品日产卡一卡二卡麻豆| 日韩午夜小视频| 91精品啪在线观看国产60岁| 欧美日韩亚洲另类| 欧美美女视频在线观看| 欧美日韩卡一卡二| 91精品国产全国免费观看| 欧美猛男超大videosgay| 在线观看视频一区二区欧美日韩| 在线影院国内精品| 欧美日韩一级片在线观看| 欧美人伦禁忌dvd放荡欲情| 7777精品伊人久久久大香线蕉超级流畅 | av在线不卡网| 91捆绑美女网站| 日本丶国产丶欧美色综合| 色菇凉天天综合网| 欧美日韩一区国产| 日韩一区二区三区免费看| 精品人伦一区二区色婷婷| 久久久久国色av免费看影院| 日本一区免费视频| 1024成人网| 亚洲成国产人片在线观看| 久久精品国产久精国产| 国产老女人精品毛片久久| 99久久精品国产精品久久| 91免费精品国自产拍在线不卡| 欧美影院精品一区| 精品久久久网站| 亚洲日本va在线观看| 亚洲一级二级三级| 免费成人在线播放| 丁香婷婷深情五月亚洲| 99久久婷婷国产精品综合| 精品视频在线免费| 精品福利在线导航| 亚洲美女区一区| 另类综合日韩欧美亚洲| 成人激情av网| 欧美一区二区免费视频| 欧美激情在线看| 天天色综合天天| 丁香六月综合激情| 欧美一区二区三区爱爱| 综合久久国产九一剧情麻豆| 日韩高清不卡一区二区| 成人精品视频一区二区三区| 欧美电影在线免费观看| 国产欧美一区二区精品仙草咪 | 欧美高清hd18日本| 久久精品网站免费观看| 日日夜夜免费精品视频| 成人动漫视频在线| 日韩一区二区三区免费看| 亚洲色图色小说| 国产精品一区免费在线观看| 欧美精品自拍偷拍动漫精品| 国产精品传媒入口麻豆| 狠狠狠色丁香婷婷综合激情 | 国产日韩欧美高清在线| 日韩激情av在线| 99精品视频在线观看| 26uuu国产一区二区三区| 亚洲成人中文在线| 99精品热视频| 国产亚洲欧洲一区高清在线观看| 天天色天天操综合| 精品视频资源站| 亚洲欧美日韩人成在线播放| 国产乱色国产精品免费视频| 欧美一区二区三区视频在线观看| 亚洲乱码精品一二三四区日韩在线 | 色诱亚洲精品久久久久久| 久久久99久久| 裸体在线国模精品偷拍| 欧美日本在线播放| 亚洲成人激情综合网| 91丝袜国产在线播放| 国产欧美一区二区三区网站| 国产一区二区调教| 欧美www视频| 国产麻豆成人传媒免费观看| 欧美mv日韩mv亚洲| 激情久久五月天| 欧美成人a视频| 国产真实精品久久二三区| 日韩一区二区免费高清| 麻豆精品一二三| 久久综合999| 高清视频一区二区| 国产精品久久久久毛片软件|