• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java Transformation类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.andengine.util.adt.transformation.Transformation的典型用法代码示例。如果您正苦于以下问题:Java Transformation类的具体用法?Java Transformation怎么用?Java Transformation使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Transformation类属于org.andengine.util.adt.transformation包,在下文中一共展示了Transformation类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: getLocalToSceneTransformation

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
@Override
public Transformation getLocalToSceneTransformation() {
	if (this.mLocalToSceneTransformation == null) {
		this.mLocalToSceneTransformation = new Transformation();
	}

	// TODO Cache if parent(recursive) not dirty.
	final Transformation localToSceneTransformation = this.mLocalToSceneTransformation;
	localToSceneTransformation.setTo(this.getLocalToParentTransformation());

	final IEntity parent = this.mParent;
	if (parent != null) {
		localToSceneTransformation.postConcat(parent.getLocalToSceneTransformation());
	}

	return localToSceneTransformation;
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:18,代码来源:Entity.java


示例2: getSceneToLocalTransformation

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
@Override
public Transformation getSceneToLocalTransformation() {
	if (this.mSceneToLocalTransformation == null) {
		this.mSceneToLocalTransformation = new Transformation();
	}

	// TODO Cache if parent(recursive) not dirty.
	final Transformation sceneToLocalTransformation = this.mSceneToLocalTransformation;
	sceneToLocalTransformation.setTo(this.getParentToLocalTransformation());

	final IEntity parent = this.mParent;
	if (parent != null) {
		sceneToLocalTransformation.preConcat(parent.getSceneToLocalTransformation());
	}

	return sceneToLocalTransformation;
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:18,代码来源:Entity.java


示例3: add

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
/**
 * @param pTextureRegion
 * @param pWidth
 * @param pHeight
 * @param pTransformation
 * @param pRed
 * @param pGreen
 * @param pBlue
 * @param pAlpha
 */
protected void add(final ITextureRegion pTextureRegion, final float pWidth, final float pHeight, final Transformation pTransformation, final float pRed, final float pGreen, final float pBlue, final float pAlpha) {
	SpriteBatch.VERTICES_TMP[0] = 0;
	SpriteBatch.VERTICES_TMP[1] = 0;

	SpriteBatch.VERTICES_TMP[2] = 0;
	SpriteBatch.VERTICES_TMP[3] = pHeight;

	SpriteBatch.VERTICES_TMP[4] = pWidth;
	SpriteBatch.VERTICES_TMP[5] = 0;

	SpriteBatch.VERTICES_TMP[6] = pWidth;
	SpriteBatch.VERTICES_TMP[7] = pHeight;

	pTransformation.transform(SpriteBatch.VERTICES_TMP);

	this.addInner(pTextureRegion, SpriteBatch.VERTICES_TMP[0], SpriteBatch.VERTICES_TMP[1], SpriteBatch.VERTICES_TMP[2], SpriteBatch.VERTICES_TMP[3], SpriteBatch.VERTICES_TMP[4], SpriteBatch.VERTICES_TMP[5], SpriteBatch.VERTICES_TMP[6], SpriteBatch.VERTICES_TMP[7], pRed, pGreen, pBlue, pAlpha);
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:28,代码来源:SpriteBatch.java


示例4: addWithPackedColor

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
/**
 * @param pTextureRegion
 * @param pWidth
 * @param pHeight
 * @param pTransformation
 * @param pColorABGRPackedInt
 */
protected void addWithPackedColor(final ITextureRegion pTextureRegion, final float pWidth, final float pHeight, final Transformation pTransformation, final float pColorABGRPackedInt) {
	SpriteBatch.VERTICES_TMP[0] = 0;
	SpriteBatch.VERTICES_TMP[1] = 0;

	SpriteBatch.VERTICES_TMP[2] = 0;
	SpriteBatch.VERTICES_TMP[3] = pHeight;

	SpriteBatch.VERTICES_TMP[4] = pWidth;
	SpriteBatch.VERTICES_TMP[5] = 0;

	SpriteBatch.VERTICES_TMP[6] = pWidth;
	SpriteBatch.VERTICES_TMP[7] = pHeight;

	pTransformation.transform(SpriteBatch.VERTICES_TMP);

	this.mSpriteBatchVertexBufferObject.addWithPackedColor(pTextureRegion, SpriteBatch.VERTICES_TMP[0], SpriteBatch.VERTICES_TMP[1], SpriteBatch.VERTICES_TMP[2], SpriteBatch.VERTICES_TMP[3], SpriteBatch.VERTICES_TMP[4], SpriteBatch.VERTICES_TMP[5], SpriteBatch.VERTICES_TMP[6], SpriteBatch.VERTICES_TMP[7], pColorABGRPackedInt);
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:25,代码来源:SpriteBatch.java


示例5: checkContains

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
public static boolean checkContains(final float pX1, final float pY1, final float pX2, final float pY2, final float pX3, final float pY3, final Transformation pTransformation, final float pX, final float pY) {
	TriangleCollisionChecker.VERTICES_CONTAINS_TMP[0 + Constants.VERTEX_INDEX_X] = pX1;
	TriangleCollisionChecker.VERTICES_CONTAINS_TMP[0 + Constants.VERTEX_INDEX_Y] = pY1;

	TriangleCollisionChecker.VERTICES_CONTAINS_TMP[2 + Constants.VERTEX_INDEX_X] = pX2;
	TriangleCollisionChecker.VERTICES_CONTAINS_TMP[2 + Constants.VERTEX_INDEX_Y] = pY2;

	TriangleCollisionChecker.VERTICES_CONTAINS_TMP[4 + Constants.VERTEX_INDEX_X] = pX3;
	TriangleCollisionChecker.VERTICES_CONTAINS_TMP[4 + Constants.VERTEX_INDEX_Y] = pY3;

	pTransformation.transform(TriangleCollisionChecker.VERTICES_CONTAINS_TMP);

	final float x1 = TriangleCollisionChecker.VERTICES_CONTAINS_TMP[0 + Constants.VERTEX_INDEX_X];
	final float y1 = TriangleCollisionChecker.VERTICES_CONTAINS_TMP[0 + Constants.VERTEX_INDEX_Y];
	final float x2 = TriangleCollisionChecker.VERTICES_CONTAINS_TMP[2 + Constants.VERTEX_INDEX_X];
	final float y2 = TriangleCollisionChecker.VERTICES_CONTAINS_TMP[2 + Constants.VERTEX_INDEX_Y];
	final float x3 = TriangleCollisionChecker.VERTICES_CONTAINS_TMP[4 + Constants.VERTEX_INDEX_X];
	final float y3 = TriangleCollisionChecker.VERTICES_CONTAINS_TMP[4 + Constants.VERTEX_INDEX_Y];

	return TriangleCollisionChecker.checkContains(x1, y1, x2, y2, x3, y3, pX, pY);
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:22,代码来源:TriangleCollisionChecker.java


示例6: fillVertices

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
public static void fillVertices(final float pLocalX, final float pLocalY, final float pLocalWidth, final float pLocalHeight, final Transformation pLocalToSceneTransformation, final float[] pVertices) {
	final float localXMin = pLocalX;
	final float localXMax = pLocalX + pLocalWidth;
	final float localYMin = pLocalY;
	final float localYMax = pLocalY + pLocalHeight;

	pVertices[0 + Constants.VERTEX_INDEX_X] = localXMin;
	pVertices[0 + Constants.VERTEX_INDEX_Y] = localYMin;

	pVertices[2 + Constants.VERTEX_INDEX_X] = localXMax;
	pVertices[2 + Constants.VERTEX_INDEX_Y] = localYMin;

	pVertices[4 + Constants.VERTEX_INDEX_X] = localXMax;
	pVertices[4 + Constants.VERTEX_INDEX_Y] = localYMax;

	pVertices[6 + Constants.VERTEX_INDEX_X] = localXMin;
	pVertices[6 + Constants.VERTEX_INDEX_Y] = localYMax;

	pLocalToSceneTransformation.transform(pVertices);
}
 
开发者ID:ArturVasilov,项目名称:AndroidCourses,代码行数:21,代码来源:EntityCollisionChecker.java


示例7: getLocalToSceneTransformation

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
@Override
public Transformation getLocalToSceneTransformation() {
	if(this.mLocalToSceneTransformation == null) {
		this.mLocalToSceneTransformation = new Transformation();
	}

	// TODO Cache if parent(recursive) not dirty.
	final Transformation localToSceneTransformation = this.mLocalToSceneTransformation;
	localToSceneTransformation.setTo(this.getLocalToParentTransformation());

	final IEntity parent = this.mParent;
	if(parent != null) {
		localToSceneTransformation.postConcat(parent.getLocalToSceneTransformation());
	}

	return localToSceneTransformation;
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:18,代码来源:Entity.java


示例8: getSceneToLocalTransformation

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
@Override
public Transformation getSceneToLocalTransformation() {
	if(this.mSceneToLocalTransformation == null) {
		this.mSceneToLocalTransformation = new Transformation();
	}

	// TODO Cache if parent(recursive) not dirty.
	final Transformation sceneToLocalTransformation = this.mSceneToLocalTransformation;
	sceneToLocalTransformation.setTo(this.getParentToLocalTransformation());

	final IEntity parent = this.mParent;
	if(parent != null) {
		sceneToLocalTransformation.preConcat(parent.getSceneToLocalTransformation());
	}

	return sceneToLocalTransformation;
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:18,代码来源:Entity.java


示例9: add

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
/**
 * @param pTextureRegion
 * @param pWidth
 * @param pHeight
 * @param pTransformation
 * @param pRed
 * @param pGreen
 * @param pBlue
 * @param pAlpha
 */
protected void add(final ITextureRegion pTextureRegion, final float pWidth, final float pHeight, final Transformation pTransformation, final float pRed, final float pGreen, final float pBlue, final float pAlpha) {
	SpriteBatch.VERTICES_TMP[0] = 0;
	SpriteBatch.VERTICES_TMP[1] = 0;

	SpriteBatch.VERTICES_TMP[2] = 0;
	SpriteBatch.VERTICES_TMP[3] = pHeight;

	SpriteBatch.VERTICES_TMP[4] = pWidth;
	SpriteBatch.VERTICES_TMP[5] = 0;

	SpriteBatch.VERTICES_TMP[6] = pWidth;
	SpriteBatch.VERTICES_TMP[7] = pHeight;

	pTransformation.transform(SpriteBatch.VERTICES_TMP);

	this.addInner(pTextureRegion, SpriteBatch.VERTICES_TMP[0], SpriteBatch.VERTICES_TMP[1], SpriteBatch.VERTICES_TMP[2], SpriteBatch.VERTICES_TMP[3],  SpriteBatch.VERTICES_TMP[4], SpriteBatch.VERTICES_TMP[5], SpriteBatch.VERTICES_TMP[6], SpriteBatch.VERTICES_TMP[7], pRed, pGreen, pBlue, pAlpha);
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:28,代码来源:SpriteBatch.java


示例10: addWithPackedColor

import org.andengine.util.adt.transformation.Transformation; //导入依赖的package包/类
/**
 * @param pTextureRegion
 * @param pWidth
 * @param pHeight
 * @param pTransformation
 * @param pColorABGRPackedInt
 */
protected void addWithPackedColor(final ITextureRegion pTextureRegion, final float pWidth, final float pHeight, final Transformation pTransformation, final float pColorABGRPackedInt) {
	SpriteBatch.VERTICES_TMP[0] = 0;
	SpriteBatch.VERTICES_TMP[1] = 0;

	SpriteBatch.VERTICES_TMP[2] = 0;
	SpriteBatch.VERTICES_TMP[3] = pHeight;

	SpriteBatch.VERTICES_TMP[4] = pWidth;
	SpriteBatch.VERTICES_TMP[5] = 0;

	SpriteBatch.VERTICES_TMP[6] = pWidth;
	SpriteBatch.VERTICES_TMP[7] = pHeight;

	pTransformation.transform(SpriteBatch.VERTICES_TMP);

	this.mSpriteBatchVertexBufferObject.addWithPackedColor(pTextureRegion, SpriteBatch.VERTICES_TMP[0], SpriteBatch.VERTICES_TMP[1], SpriteBatch.VERTICES_TMP[2], SpriteBatch.VERTICES_TMP[3],  SpriteBatch.VERTICES_TMP[4], SpriteBatch.VERTICES_TMP[5], SpriteBatch.VERTICES_TMP[6], SpriteBatch.VERTICES_TMP[7], pColorABGRPackedInt);
}
 
开发者ID:peterchaula,项目名称:ClassicF1,代码行数:25,代码来源:SpriteBatch.java



注:本文中的org.andengine.util.adt.transformation.Transformation类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java DistributedRPCInvocations类代码示例发布时间:2022-05-23
下一篇:
Java HelpUtils类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap