[android-developers] scrollview can't work programmatically

2011-10-09 Thread billconan
Hello guys, I want to use scrollview in my app. I tried to add a text view into the scrollview, but I can't see anything rendered, except the background color of the scroll view. here is how I did it: public class MyView extends ViewGroup { ScrollView myScrollview; Textview tv;

[android-developers] setAlpha is gone?

2011-10-02 Thread billconan
Hello, I want to write some transparent view, but there is no setAlpha defined with View, although the document claims that there is. I am wondering if setAlpha is deprecated? And how am I suppose to set alpha? Thank you very much, -- You received this message because you are subscribed to the

[android-developers] Re: custom viewgroup with a background.

2011-09-08 Thread billconan
Sorry, I shouldn't use different names. I guess I am too new to JAVA On Sep 8, 5:47 am, TreKing treking...@gmail.com wrote: On Wed, Sep 7, 2011 at 11:58 PM, billconan billco...@gmail.com wrote: suppose I have a function named kkk Why ... why would you name your function that ... ? which

[android-developers] custom viewgroup with a background.

2011-09-07 Thread billconan
Hello guys, I want to create a custom widget. Basically it is something like a toolBar, I want to draw a background first, and draw my tool buttons on top of the background. However, it doesn't work. What I did is I overrided the onDraw Function @Override protected void onDraw(Canvas canvas)

[android-developers] text wrap around image with render script.

2011-06-21 Thread billconan
Hello guys, two questions, I want to implement text wrapping image, with java or render script, how can i do that? The document for android text is very unclear without any example, and it seems that wrapping is not possible. how about render script? I noticed that the youtube app coming with

[android-developers] Re: unable to run the renderscript samples.

2011-05-23 Thread billconan
that other folks with Xooms are having that same problem. On May 13, 3:37 am, billconan billco...@gmail.com wrote: the problem has things to do with the path and folder of the renderscript intermediate binary file. it cannot find the cached intermediate binary under the folder /data/data

[android-developers] unable to run the renderscript samples.

2011-05-12 Thread billconan
Hello guys, I am trying out the renderscript samples on my samsung galaxy 10.1 tablet. so far it is not very successful. The render script cannot be loaded. 05-12 17:16:20.670: ERROR/AndroidRuntime(13959): Caused by: android.renderscript.RSRuntimeException: Loading of ScriptC script failed.

[android-developers] Re: unable to run the renderscript samples.

2011-05-12 Thread billconan
the problem has things to do with the path and folder of the renderscript intermediate binary file. it cannot find the cached intermediate binary under the folder /data/data/com.android.example/ -- You received this message because you are subscribed to the Google Groups Android

[android-developers] question about the proper way of quitting the program

2010-12-02 Thread billconan
Hello guys, I'm working on a game, mainly based on NDK. I now have a problem of how to quit the application. Right now, i just implement my own function to handle the back button. inside that function, I simply call the activity.finish() api to finish the activity that uses my C++ code. However,

[android-developers] force resolution be be higher than 800*480

2010-11-15 Thread billconan
Hello guys, I'm working on a game application and because the testing phones i use have 800*480 and 854*480 resolutions, I created my game assets based on 800*480 resolutions. supporting low resolution will result in changing lots of my code. and the game experience on low resolution screens will

[android-developers] Re: force resolution be be higher than 800*480

2010-11-15 Thread billconan
thank you. guess i will have to detect the screen size in the program and pop some warning. On Nov 15, 12:38 pm, Mark Murphy mmur...@commonsware.com wrote: On Mon, Nov 15, 2010 at 3:34 PM, billconan billco...@gmail.com wrote: I'm working on a game application and because the testing phones i

[android-developers] somebody stole our app and resale it on the market.

2010-09-09 Thread billconan
today, i read an article http://www.itsbeach.com/blog/2010/08/developing-for-android.html and i'm afraid that i have to agree with this article. although i claimed myself as an android fan and use an android phone, i have to agree that iphone is a much better product. i picked up android for

[android-developers] Re: somebody stole our app and resell it on the market.

2010-09-09 Thread billconan
We will think of ways to stop him. and perhaps in our next release we will consider using ndk to encrypt our logo and strings. but this will sacrifice the performance. But more importantly, I think this is a fundamental fault of the android platform. Java is so easy to hack and so slow. Ndk

[android-developers] problem with GL_CLAMP_TO_EDGE

2010-09-05 Thread billconan
hello guys, I cannot guarantee my texture size be a power of two, therefore, i'm using GL_CLAMP_TO_EDGE, but when i call glTexImage2D, or glutil.teximage2d, i always get the Opengl Error Code 1281 Invalid Value. this same setting seems to work on iphone. does this mean that android only

[android-developers] is .pvr textures supported by 2.2 devices? how do i load them?

2010-08-26 Thread billconan
hello everyone, i'm porting an iphone opengl project to android. and have some questions about pvr texture maps. i have two kinds of texture maps png and pvr. for pngs i use Bitmap to load them, which worked fine. but pvr texture maps, i have no idea how to load them with Android can somebody

[android-developers] get files under certain directory

2010-08-24 Thread billconan
hello guys, this sounds simple, but i couldn't find any api from the reference. i want to get all the files under certain directory on the sd card. can you point me to the correct function? thanks. -- You received this message because you are subscribed to the Google Groups Android

[android-developers] Touch event noisy

2010-07-21 Thread billconan
Hello everyone. I'm working on a simple game: when you press a button on the screen, a character will run to certain direction. it's easy to support keyboard input. but, some phone doesn't go with a keyboard or even no a track ball. so I decided to draw a virtual run key on the screen (with

[android-developers] how do you guys feel about the develop tools?

2010-07-21 Thread billconan
hello guys, i really like android and hope that it can surpass iphone in the near future. I like it, because it's open. But i really don't like the develop tools of android. it is so slow and buggy. Specifically, I don't like these two things: Eclipse Android emulator. Sometimes, the debugger

[android-developers] widget doesn't fresh on verizon droid, but works fine on HTC eris.

2010-05-02 Thread billconan
hello guys, I'm developing a widget based on this tutorial. http://android-developers.blogspot.com/2009/04/introducing-home-screen-widgets-and.html the same code works fine on my HTC eris. but on the verizon droid, the widget doesn't refresh. the widget updates the time i add it on the home

[android-developers] touch down event missing in glsurfaceview.

2010-04-02 Thread billconan
hi, because glsurfaceview uses 2 threads to handle UI and rendering, to reduce flickring, i need to pass a motionevent from the ui thread to the render thread. this is documented here at the official reference:

[android-developers] Re: touch down event missing in glsurfaceview.

2010-04-02 Thread billconan
flooded and that is why i cannot see the touch down event. how do i solve this? On Apr 2, 1:14 pm, billconan billco...@gmail.com wrote: hi, because glsurfaceview uses 2 threads to handle UI and rendering, to reduce flickring, i need to pass a motionevent from the ui thread to the render thread

[android-developers] Re: touch down event missing in glsurfaceview.

2010-04-02 Thread billconan
further tests have proved my guess. it is because the event queue flooding. after changing my event handling function to this, i have solved this problem: basically i let the ui thread sleep a little while after seeing the touch down event, to make sure the render see that event. however, i'm

[android-developers] OpenGL ES flickering problems?

2010-04-01 Thread billconan
Hello everyone, I'm working on a game that need user to move a map with fingers. but i noticed bad flickering problems when i try to update the position and texture map of the rendering object in the motionevent handler. It seems that the opengl draw the objects before i finish handling the

[android-developers] vm out-of-memory problem

2010-02-25 Thread billconan
hello everyone, i'm writing a game. i want to use a large bitmap to cache the game map, because the map doesn't change during the game play. the game map is tile based, but i want to draw it at the beginning of the game, so i can easy scroll the map. problem is, the bitmap can be very large, for

[android-developers] how is a 3G phone assigned an ip address?

2009-12-10 Thread billconan
hello guys, i'm wondering how is a 3g phone is assigned an ip address? is it like adsl? or is it like an inner network (Network Address Translation )? if i want to implement a p2p application, i need to dig hole on the inner network right? -- You received this message because you are