Android/G1 framebuffer driver

by yarik...@gmail.com » Fri, 10 Apr 2009 12:53:22 GMT


Sponsored Links
 Where can I find framebuffer driver?

There are a lot of sources in git and I can't find out wich one is
used for MSM7201A chipset used in G1. Thanks for response.
--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---



Android/G1 framebuffer driver

by yarik...@gmail.com » Fri, 10 Apr 2009 15:08:53 GMT


 ok.. I've got it: [kernel/msm.git] / drivers / video / msm / msm_fb.c
--~--~---------~--~----~------------~-------~--~----~

-~----------~----~----~----~------~----~------~--~---


Sponsored Links


Other Threads

1. GraphicsActivity Problem

Hi,

I like to do this simple graphics oriented program.
But i can't able to do this. B'coz i can't able to extend GraphicsActivity
Class.
I don't know why?


Any body know about these?....


my code is given below....

/*
 * Copyright (C) 2007 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

import android.app.Activity;
import android.content.Context;
import android.graphics.*;
import android.os.Bundle;
import android.view.KeyEvent;
import android.view.*;

import java.io.InputStream;
import java.io.ByteArrayOutputStream;

public class AlphaBitmap extends GraphicsActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(new SampleView(this));
    }

    private static class SampleView extends View {
        private Bitmap mBitmap;
        private Bitmap mBitmap2;
        private Bitmap mBitmap3;
        private Shader mShader;

        private static void drawIntoBitmap(Bitmap bm) {
            float x = bm.getWidth();
            float y = bm.getHeight();
            Canvas c = new Canvas(bm);
            Paint p = new Paint();
            p.setAntiAlias(true);

            p.setAlpha(0x80);
            c.drawCircle(x/2, y/2, x/2, p);

            p.setAlpha(0x30);
            p.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC));
            p.setTextSize(60);
            p.setTextAlign(Paint.Align.CENTER);
            Paint.FontMetrics fm = p.getFontMetrics();
            c.drawText("Alpha", x/2, (y-fm.ascent)/2, p);
        }

        public SampleView(Context context) {
            super(context);
            setFocusable(true);

            InputStream is =
context.getResources().openRawResource(R.drawable.app_sample_code);
            mBitmap = BitmapFactory.decodeStream(is);
            mBitmap2 = mBitmap.extractAlpha();
            mBitmap3 = Bitmap.createBitmap(200, 200, Bitmap.Config.ALPHA_8);
            drawIntoBitmap(mBitmap3);

            mShader = new LinearGradient(0, 0, 100, 70, new int[] {
                                         Color.RED, Color.GREEN, Color.BLUE
},
                                         null, Shader.TileMode.MIRROR);
        }

        @Override protected void onDraw(Canvas canvas) {
            canvas.drawColor(Color.WHITE);

            Paint p = new Paint();
            float y = 10;

            p.setColor(Color.RED);
            canvas.drawBitmap(mBitmap, 10, y, p);
            y += mBitmap.getHeight() + 10;
            canvas.drawBitmap(mBitmap2, 10, y, p);
            y += mBitmap2.getHeight() + 10;
            p.setShader(mShader);
            canvas.drawBitmap(mBitmap3, 10, y, p);
        }
    }
}




-- 
Thanks & Regards
Sasikumar.S

-- 

2. how to do call interception

Hello all.

Please give me some advice after you read the message below.

Originally, the purpose of a call button is making a call through
network such as GSM, CDMA network etc.
But I want to give a option to users to choose VoIP call or general
call when they push call button.
Is it possible? Somebody told me it might be possible if I could
intercept call event. But I don't understand exactly.

Help, please. :)

-- 

3. Bagi2 invitation google wave

4. Best practice for supporting all devices (varying sdks...)

5. Popular apps vanished!

6. launchMode problem

7. passing multi dimensional string array between two actvities.