canvas的常见属性 属性 值 描述 height pixels 设置 canvas 的高度。 width pixels 设置 canvas 的宽度。 Canvas的APIcanvas主要属性和方法 方法 描述 save() 保存当前环境的状态 restore() 返回之前保存过的路径状态和属性 ...
分类:
其他好文 时间:
2016-05-16 14:30:20
阅读次数:
161
首先说一下canvas类:Class Overview
The Canvas class holds the "draw" calls. To draw something, you need 4 basic components: A Bitmap to hold the pixels, a Canvas to host the draw calls (writing into the bitma...
分类:
移动开发 时间:
2016-05-15 00:40:55
阅读次数:
308
Getting or Setting Pixels The safe (slow) way Suppose you are working on an Image<Bgr, Byte>. You can obtain the pixel on the y-th row and x-th column ...
分类:
其他好文 时间:
2016-05-10 23:42:54
阅读次数:
190
转换成某区间上被k整除的数字有几个。 处理出每一段有几种,然后乘一下就是答案。 ...
分类:
其他好文 时间:
2016-05-07 22:01:29
阅读次数:
167
更改电脑屏幕显示的文字大小后,平面显示区域问题。 /// <summary> /// 屏幕显示尺寸 /// </summary> public static Size ReviseScreenSize { get { float pixels = getLogPiex(); float dxPrec ...
记得之前学习中有位老师说过我们经常使用的尺寸单位为dp和sp,而这两个单位有什么区别在今天的学习中和我遭遇了。在书中描述的代码中,反复出现比较多的是dp,px。所以呢,想趁着这个机会搞清涉及的尺寸单位,免得以后再在这个问题上浪费时间。 px:pixels,每个像素对应着屏幕上的一个点,一般作为分辨率 ...
分类:
移动开发 时间:
2016-05-03 20:15:10
阅读次数:
232
离屏渲染(Offscreen Render) objc.io 出品的 Getting Pixels onto the Screen 的翻译版绘制像素到屏幕上应该是国内对离屏渲染这个概念推广力度最大的一篇文章了。文章里提到「直接将图层合成到帧的缓冲区中(在屏幕上)比先创建屏幕外缓冲区,然后渲染到纹理中 ...
分类:
其他好文 时间:
2016-04-28 09:27:07
阅读次数:
288
移动设备的用户越来越多,每天android手机的激活量都已经超过130万台,所以我们面向移动终端的WebAPP也开始跟进了。本文主要介绍webapp的开发与调试的相关知识和经验,以及给出几种可选的解决方案。 一、基本概念 (1) CSS pixels与device pixels CSS pixels ...
分类:
移动开发 时间:
2016-04-26 13:55:36
阅读次数:
206
Squats Time Limit: 1000MS Memory Limit: 262144KB 64bit IO Format: %I64d & %I64u Submit Status Description Pasha has many hamsters and he makes them wo ...
分类:
其他好文 时间:
2016-04-23 19:52:41
阅读次数:
185
Pasha and String Time Limit:2000MS Memory Limit:262144KB 64bit IO Format:%I64d & %I64u Submit Status Practice CodeForces 525B Pasha and String Submit ...
分类:
其他好文 时间:
2016-04-20 23:48:32
阅读次数:
202