通过彩色像素到特定图像的运动?

时间:2012-02-02 05:44:48

标签: android android-animation android-canvas

我准备了自定义视图代码,

  if (myBitmap == null) {
        myBitmap = Bitmap.createBitmap(290, 330, Bitmap.Config.ARGB_8888);
        bmpCanvas = new Canvas(myBitmap);
        intArray = new int[myBitmap.getWidth()
                * myBitmap.getHeight()];
        }

               if (bmpCanvas != null) {
                 bmpCanvas.drawText("C", 80,280, mPaintAlphabet);

         bmpCanvas.drawText("C", 80,280, mAlphaInner);
                }
                myBitmap.getPixels(intArray, 0, 290, 0, 0, 290, 330);
                if (myBitmap != null)
        canvas.drawBitmap(myBitmap, 0, 0, null);

这里intArray有总像素,有些像素有color.i收集单独数组中的总颜色像素。请让我知道我可以通过彩色像素对特定图像进行动作吗?

0 个答案:

没有答案