本文整理了Java中android.graphics.Camera.<init>()
方法的一些代码示例,展示了Camera.<init>()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Camera.<init>()
方法的具体详情如下:
包路径:android.graphics.Camera
类名称:Camera
方法名:<init>
暂无
代码示例来源:origin: ybq/Android-SpinKit
public Sprite() {
mCamera = new Camera();
mMatrix = new Matrix();
}
代码示例来源:origin: jdsjlzx/LRecyclerView
public BallPulseRiseIndicator(){
mCamera=new Camera();
mMatrix=new Matrix();
}
代码示例来源:origin: jdsjlzx/LRecyclerView
public TriangleSkewSpinIndicator(){
mCamera=new Camera();
mMatrix=new Matrix();
}
代码示例来源:origin: jdsjlzx/LRecyclerView
public SquareSpinIndicator(){
mCamera=new Camera();
mMatrix=new Matrix();
}
代码示例来源:origin: Yalantis/Side-Menu.Android
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
mCamera = new Camera();
}
代码示例来源:origin: JingYeoh/FragmentRigger
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
mCamera = new Camera();
if (mType == TYPE_SCALE) {
mCenterX = width * mCenterX;
mCenterY = height * mCenterY;
mDepthZ = width * mDepthZ;
}
}
代码示例来源:origin: ImmortalZ/StereoView
/**
* 初始化数据
*/
private void init(Context context) {
mTouchSlop = ViewConfiguration.get(getContext()).getScaledTouchSlop();
mCamera = new Camera();
mMatrix = new Matrix();
if (mScroller == null) {
mScroller = new Scroller(context);
}
}
代码示例来源:origin: Ramotion/folding-cell-android
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
this.mCamera = new Camera();
mCamera.setLocation(0, 0, -mCameraHeight);
代码示例来源:origin: AigeStudio/WheelPicker
mCamera = new Camera();
代码示例来源:origin: JingYeoh/FragmentRigger
@Override
protected void applyTransformation(float interpolatedTime, Transformation t) {
Camera camera = new Camera();
camera.save();
// 设置camera动作为绕Y轴旋转
// 总共旋转180度,因此计算在每个补间时间点interpolatedTime的角度即为两着相乘
// camera.rotateX(deg * interpolatedTime);
camera.rotateY(180 * interpolatedTime);
// camera.rotateZ(180 * interpolatedTime);
//
// 根据camera动作产生一个matrix,赋给Transformation的matrix,以用来设置动画效果
Matrix matrix = t.getMatrix();
camera.getMatrix(matrix);
camera.restore();
//经过以下平移,才能以view的中心点进行翻转
matrix.preTranslate(-view.getWidth() / 2, -view.getHeight() / 2);
matrix.postTranslate(view.getWidth() / 2, view.getHeight() / 2);
}
}
代码示例来源:origin: stackoverflow.com
centerX = width/2;
centerY = height/2;
camera = new Camera();
代码示例来源:origin: gjiazhe/MultiChoicesCircleButton
public void setParallaxEnabled(boolean enabled) {
this.mParallaxEnabled = enabled;
if (enabled) {
mCamera = new Camera();
mMatrix = new Matrix();
} else {
mCamera = null;
mMatrix = null;
}
}
代码示例来源:origin: geminiwen/AndroidCubeDemo
public CubeLayout2(Context context, AttributeSet attrs) {
this(context, attrs, 0);
this.mCamera = new Camera();
this.mMatrix = new Matrix();
this.mStartTime = System.currentTimeMillis();
}
代码示例来源:origin: zhangyuChen1991/Roll3DImageView
private void init(Context context) {
bitmapList = new ArrayList<>();
paint = new Paint(Paint.ANTI_ALIAS_FLAG);
camera = new Camera();
matrix = new Matrix();
this.context = context;
}
代码示例来源:origin: GcsSloop/ViewSupport
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
mCamera = new Camera();
}
代码示例来源:origin: PopFisher/AndroidRotateAnim
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
mCamera = new Camera();
}
代码示例来源:origin: sharish/CreditCardView
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
camera = new Camera();
}
代码示例来源:origin: sromku/memory-game
@Override
public void initialize(int width, int height, int parentWidth, int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
centerX = width / 2;
centerY = height / 2;
camera = new Camera();
}
代码示例来源:origin: dbachelder/CreditCardEntry
@Override
public void initialize(int width, int height, int parentWidth,
int parentHeight) {
super.initialize(width, height, parentWidth, parentHeight);
camera = new Camera();
}
代码示例来源:origin: yaozs/YzsBaseActivity
@Override
protected void applyTransformation(float interpolatedTime, Transformation t) {
Matrix matrix = t.getMatrix();
Camera camera = new Camera();
camera.save();
camera.rotateY(720 * interpolatedTime);
camera.getMatrix(matrix);
camera.restore();
matrix.preTranslate(-mCenterX, -mCenterY);
matrix.postTranslate(mCenterX, mCenterY);
}
}
内容来源于网络,如有侵权,请联系作者删除!