Android :: IntBuffer Overflow - OpenGL ES

Feb 2, 2009

I am trying to optimize the OpenGL ES rendering pipeline, along with general optimizations for a proof of concept. One thing I did was to take vertex and texture coordinate float[] data and FloatBuffer that are passed to gl*Pointer methods and convert them into int[] data and IntBuffer objects, because I am using GL_FIXED and fixed point math. After initializing/allocateDirect()'ing the IntBuffers and put()'ing the int[] data in them for the first time, the render() method is called once per frame. After the rendering, the int[] data is updated for both vertex and texture data. Then, the following methods are called on the IntBuffer objects: -vertices_buffer.clear() vertices_buffer.put(vertices) // vertices is a int []-vertices_buffer .position(0) This was not problem when using float[] and FloatBuffer, but a BufferOverflow Exception is being thrown on that call to put(). The API says this is only thrown when the remaining size of the IntBuffer is less than the length of the int[] passed in. Well, both of those values are output to the log on the line just prior to calling put() (intBuf.remaining() and intArr.length). They both output 600, and last I checked 600 is not less than 600! I figure I am missing something simple. I checked the call made to allocateDirect() and it looks like this: -vertices_direct = ByteBuffer.allocateDirect (vertices.length * (Integer.SIZE >> 3));-vertices_ direct. order (ByteOrder.nativeOrder ());-vertices_buffer = vertices_direct.asIntBuffer(); The original code (using floating point math and Android SDK m3-rc37a) can be found here: http://www. enfis.it /wp-content /uploads/2008/01/tunnel3d.zip http://www.enfis.it /archives/14 Obviously, I had to convert the original code up to Android SDK 1.0 r2. I ended up using EGL as I did not see a way around it.Keep in mind I have little OpenGL experience, let alone ES 1.0 on Android.

Android :: IntBuffer Overflow - OpenGL ES


Android :: Bug In IntBuffer.put() When Using Direct Buffers

Jun 16, 2009

In a process of switching from indirect to direct buffers for OpenGL geometry specification I've found a problem with the following function in java.nio.IntBuffer class: IntBuffer put(int[] src, int off, int len) this function is supposed to do a bulk transfer of int data from the given array starting at the specified offset. It should be an optimized version of the following code: for (int i = 0; i < len; i++) {buffer.put(src[off + i]);}

View 2 Replies View Related

Android :: OpenGL Speed Issue - Code Contribution To Other OpenGL

Feb 25, 2009

Single Threaded OpenGL game ! (check bottom, you can download and use the helper class) Lighting disabled ! Depth Buffer disabled ! Culling enabled ! Textures disabled !

Just 176 integers (x,y values only) making 88 vertexes along with 132 index numbers making "44 triangles only"

Framerates I get is

with GL_BLENDING disabled - 145 fps approx only! enabled - 110 fps approx only!

I have the screenshot of exact code in the draw function here.. just 2 damn lines ! I have hidden only the comments.. click here to see it http://prasna991.googlepages.com/drawframe.png

variable details in the 2 lines of code =========================== ipts = 176 elements (only x and y for each vertex) totallinetriangles * 3 = 176 lineindexes = 132 elements - type "short"

Here is the screenshot of output drawing and how it will look like http://prasna991.googlepages.com/screen.png

OpenGL single threaded Initialization Helper ================================ Here is my OpenGL helper class.. makes the OpenGL initialization for newbies a cakewalk http://prasna991.googlepages.com/OpenGLHelperclass.txt

I tested by rendering on the touch event only.. frame rate drops only when u touch and drag and here I have just tested by tapping and releasing gently on the emulator and on the device

Is this the device limitations ? So graphics is actually a lot lot lot slower than on iPhone ?

View 8 Replies View Related

Android :: NDK OpenGL - Mixing Java And Native - C - Calls To OpenGL API

Jul 24, 2010

I would like to be able to use the OpenGL API from both Java and C (via NDK).

In Java, there is a GL object passed, which has all GL methods on it.

In C, you just talk to the native library.

In a single onDrawFrame callback (for which Java is passed a GL), can I use methods on the GL object, and also call NDK methods which access the openGL library?

In other words, is the GL object just a wrapper for the same instance of the native library?

View 3 Replies View Related

Android :: Webview Iframe Overflow

Sep 20, 2010

I'm currently building a web app in android. My app runs in a webview, and loads third-party contents through iframs. The iframe size is fixed and supposed not to be changed by the content loaded. In desktop Chrome browser, it works fine and the overflow part of loaded content can be scrolled via scrollbars. However, in android webview, the iframe tends to resize itself based on the contents loaded, which leads to a mess of the page layout.
Does anyone have encountered the same problem?

View 3 Replies View Related

Android :: LinearLayout Stack Overflow Fails On 1.5 - Ok On 1.6?

Nov 8, 2009

I'm trying to make a horizontal layout with two TextViews, one should take up 40% of available width, the other 60%. This works unless the text is longer than available space, then a stack overflow exception is thrown. Pasting this into an empty 1.5 project xml file should cause it (though this seems to work ok on 1.6+):

<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/ android" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:weightSum="100" >

<TextView android:layout_width="0dip" android:layout_height="wrap_content" android:layout_weight="40" android:text="Some really long sentence AAAAA" android:singleLine="true" />

<TextView android:layout_width="0dip" android:layout_height="wrap_content" android:layout_weight="60" android:text="Some really long sentence BBBBB" android:singleLine="true" /> </LinearLayout>
Is there some other way to do this? I need to just break a row up into these separate columns with specific widths. I'm ok with the text just getting truncated on overflow,

View 5 Replies View Related

Android :: AutoLink Cause Stack Overflow Exception

Dec 16, 2009

I tried to create the launcher widget for getting some messages from social networking server. I hope it can support autoLink feature of these message content. however, it will have the "Stack Overflow exception" when android:autoLink="web|email" is enabled when getting more than 20 messages. this issue doesn't happened when I remove this parameter. would you please share your experience about this issue?

View 2 Replies View Related

Android :: Avoiding Activity Stack Overflow

Sep 17, 2009

I have the following situation. I have a task with the following activity stack -- A - B - C I have a menu item that allows me to start activity D; so my activity stack looks like this -- A - B - C - D Then I could select a menu item that allows me to start an activity C, which would cause my activity stack to look like this: A - B - C - D - C Then I could go back (via the menu item) to activity D, making my activity stack look like this: A - B - C - D - C - D Doing this a few more times, it would wind up looking like this -- A - B - C - D - C - D - C - D - C - D - C - D - C - D - C - D - C - D - C - D - C - D This seems kinda stupid to me. I'd like it to simply re-use an activity, or pop the activity below to be on top (which goes against the nature of a "stack"). So, what I mean is if I had this activity stack: A - B - C - D And I started activity C (from the menu), I would get: A - B - D - C And if I then started activity D (from the menu), I would get: A - B - C - D Is there a way to do this without keeping some global list of activities and doing gross things to them to reorder them?

View 3 Replies View Related

Android :: Creating Stack Overflow Notifier

May 11, 2010

I could not find a Stack Overflow notifier Android app so I am planning on making one. I hope that my app will serve a similar purpose as the Stack Overflow Notifier Chrome extension. This will be my first Android app so I am still unfamiliar with the platform.So I currently plan to ask the user to login by bringing up a WebView and then access the Recent Activity page in the background at specific intervals.My question:How can I store the authentication cookie from StackOverflow after the user has logged in through the WebView and then send this cookie in the HttpGet request when accessing the Recent Activity page?

View 1 Replies View Related

Android :: Equivalent To Overflow Property In Linear Layout On SDK?

Nov 6, 2009

I've been trying to create a color LinearLayout object (1) within another LinearLayout object (2), while having (1) not display beyond the bounds of (2) - in short, I wish to assign the equivalent of the CSS overflow:hidden property to LinearLayout (2) so that LinearLayout (1) doesn't bleed beyond the edges of (2).
<LinearLayout>
<!-- (2) -->
<LinearLayout>
<!-- (1) -->
</LinearLayout>
</LinearLayout> Is this possible within Android?

View 1 Replies View Related

Android :: Webkit Text Overflow - Ellipsis Not Working

Oct 27, 2010

i am trying to get the following code to work on an androind 2.1 phone (HTC Sense UI):
h1 {font-size: 14px;
font-weight: bold;
color: #FFF;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden; however, the text-overflow property does not seem to work. has anybody else had this problem, or found a way to work around it?

View 1 Replies View Related

Android :: Native Process Provoke ReferenceTable Overflow After While

Nov 13, 2010

Using the ndk I have compiled a code written in C. The program is a ecm format files conversion, here the native code: link . I chose to do with JNI for reasons of optimization, because the program requires a large amount of CPU processing.The files to convert can be very large, between 200mb and 700mb. Everything works perfectly, but when trying to convert files bigger than 600Mb, near the end of the conversion process, the application stops with the following error message:
11-13 20:24:36.775: WARN/dalvikvm(1468): ReferenceTable overflow (max=512)
11-13 20:24:36.775: WARN/dalvikvm(1468): Last 10 entries in JNI local reference table:
11-13 20:24:36.775: WARN/dalvikvm(1468): 502: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.775: WARN/dalvikvm(1468): 503: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.775: WARN/dalvikvm(1468): 504: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.775: WARN/dalvikvm(1468): 505: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.775: WARN/dalvikvm(1468): 506: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.775: WARN/dalvikvm(1468): 507: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.775: WARN/dalvikvm(1468): 508: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.786: WARN/dalvikvm(1468): 509: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.786: WARN/dalvikvm(1468): 510: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.786: WARN/dalvikvm(1468): 511: 0x465117b0 cls=Ljava/lang/Class; 'Lunecm4droid/kiio/es/mainUECM;' (164 bytes)
11-13 20:24:36.786: WARN/dalvikvm(1468): JNI local reference table summary (512 entries):
11-13 20:24:36.786: WARN/dalvikvm(1468): 512 of Ljava/lang/Class; 164B (1 unique)
11-13 20:24:36.786: WARN/dalvikvm(1468): Memory held directly by tracked refs is 164 bytes
11-13 20:24:36.786: ERROR/dalvikvm(1468): Failed adding to JNI local ref table (has 512 entries)
11-13 20:24:36.786: INFO/dalvikvm(1468): "Thread-9" prio=5 tid=8 RUNNABLE
11-13 20:24:36.786: INFO/dalvikvm(1468): | group="main" sCount=0 dsCount=0 s=N obj=0x46523c48 self=0x30e960
11-13 20:24:36.786: INFO/dalvikvm(1468): | sysTid=1506 nice=0 sched=0/0 cgrp=default handle=2542616
11-13 20:24:36.786: INFO/dalvikvm(1468): | schedstat=( 200042694099 61087921121 333928 )
11-13 20:24:36.786: INFO/dalvikvm(1468): at unecm4droid.kiio.es.mainUECM.invokeNativeFunction(Native Method)
11-13 20:24:36.786: INFO/dalvikvm(1468): at unecm4droid.kiio.es.mainUECM.access$10(mainUECM.java:490)
11-13 20:24:36.786: INFO/dalvikvm(1468): at unecm4droid.kiio.es.mainUECM$11.run(mainUECM.java:735)
11-13 20:24:36.786: ERROR/dalvikvm(1468): VM aborting
11-13 20:24:36.795: INFO/DEBUG(121): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
11-13 20:24:36.795: INFO/DEBUG(121): Build fingerprint: 'google/passion/passion/mahimahi:2.2/FRF91/43546:user/release-keys'
11-13 20:24:36.795: INFO/DEBUG(121): pid: 1468, tid: 1506 >>> unecm4droid.kiio.es <<<
11-13 20:24:36.795: INFO/DEBUG(121): signal 11 (SIGSEGV), fault addr deadd00d
11-13 20:24:36.795: INFO/DEBUG(121): r0 00000026 r1 afd14699 r2 afd14699 r3 00000000
11-13 20:24:36.795: INFO/DEBUG(121): r4 802a3448 r5 802a3448 r6 0030e960 r7 0030e9b0
11-13 20:24:36.795: INFO/DEBUG(121): r8 464c9b48 r9 43277fa4 10 43277f8c fp 464c9ed8
11-13 20:24:36.795: INFO/DEBUG(121): ip deadd00d sp 464c9130 lr afd16155 pc 802424e0 cpsr 20000030
11-13 20:24:36.795: INFO/DEBUG(121): d0 643a64696f72646e d1 6472656767756265
11-13 20:24:36.795: INFO/DEBUG(121): d2 465117b046511767 d3 465117b04651170a
11-13 20:24:36.795: INFO/DEBUG(121): d4 465117b0465117b0 d5 465117b0465117b0
11-13 20:24:36.795: INFO/DEBUG(121): d6 465117b0465117b0 d7 465117b0465117b0
11-13 20:24:36.795: INFO/DEBUG(121): d8 4198000041b80000 d9 43e0000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d10 41dfffffffc00000 d11 c3e0000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d12 0000000000000000 d13 0000000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d14 0000000000000000 d15 0000000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d16 47d7202800000000 d17 c083180000000000
11-13 20:24:36.795: INFO/DEBUG(121): d18 4035000000000000 d19 0000000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d20 3ff0000000000000 d21 8000000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d22 c035000000000000 d23 ff00080008000700
11-13 20:24:36.795: INFO/DEBUG(121): d24 ff00080008000700 d25 ff00080008000700
11-13 20:24:36.795: INFO/DEBUG(121): d26 0100010001000100 d27 0100010001000100
11-13 20:24:36.795: INFO/DEBUG(121): d28 0100010001000100 d29 3ff0000000000000
11-13 20:24:36.795: INFO/DEBUG(121): d30 0000000000000000 d31 3ff0000000000000
11-13 20:24:36.795: INFO/DEBUG(121): scr 80000012
11-13 20:24:36.865: INFO/DEBUG(121): #00 pc 000424e0 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #01 pc 0004655e /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #02 pc 000466f0 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #03 pc 00001110 /data/data/unecm4droid.kiio.es/lib/libndkfoo.so
11-13 20:24:36.865: INFO/DEBUG(121): #04 pc 000016da /data/data/unecm4droid.kiio.es/lib/libndkfoo.so
11-13 20:24:36.865: INFO/DEBUG(121): #05 pc 00001bda /data/data/unecm4droid.kiio.es/lib/libndkfoo.so
11-13 20:24:36.865: INFO/DEBUG(121): #06 pc 00001f2e /data/data/unecm4droid.kiio.es/lib/libndkfoo.so
11-13 20:24:36.865: INFO/DEBUG(121): #07 pc 00017034 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #08 pc 00045744 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #09 pc 0004ae8e /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #10 pc 0001bf98 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #11 pc 00022bc4 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #12 pc 00021a60 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #13 pc 0005cf60 /system/lib/libdvm.so
11-13 20:24:36.865: INFO/DEBUG(121): #14 pc 0005d190 /system/lib/libdvm.so
11-13 20:24:36.876: INFO/DEBUG(121): #15 pc 000500d0 /system/lib/libdvm.so
11-13 20:24:36.876: INFO/DEBUG(121): #16 pc 00010f44 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): #17 pc 00010a30 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): code around pc:
11-13 20:24:36.876: INFO/DEBUG(121): 802424c0 20061861 f7d418a2 2000ea7c ebdaf7d4
11-13 20:24:36.876: INFO/DEBUG(121): 802424d0 58234808 b1036bdb f8df4798 2026c01c
11-13 20:24:36.876: INFO/DEBUG(121): 802424e0 0000f88c ec40f7d4 00060f8c fffe1ecc
11-13 20:24:36.876: INFO/DEBUG(121): 802424f0 fffe5140 000003a4 deadd00d f8dfb40e
11-13 20:24:36.876: INFO/DEBUG(121): 80242500 b503c02c bf00490a 188ba200 f853aa03
11-13 20:24:36.876: INFO/DEBUG(121): code around lr:
11-13 20:24:36.876: INFO/DEBUG(121): afd16134 000ef9b0 22022100 ec98f7f7 463289a1
11-13 20:24:36.876: INFO/DEBUG(121): afd16144 5080f421 81a04629 000ef9b4 ec1ef7f7
11-13 20:24:36.876: INFO/DEBUG(121): afd16154 bf00bd70 4604b510 000ef9b0 ec06f7f7
11-13 20:24:36.876: INFO/DEBUG(121): afd16164 bfbe2800 f42389a3 81a35380 6d21db02
11-13 20:24:36.876: INFO/DEBUG(121): afd16174 6523180b bf00bd10 b085b5f0 bf004c41
11-13 20:24:36.876: INFO/DEBUG(121): stack:
11-13 20:24:36.876: INFO/DEBUG(121): 464c90f0 000005a0
11-13 20:24:36.876: INFO/DEBUG(121): 464c90f4 afd146c9 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c90f8 afd42498 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c90fc afd43bc8 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c9100 00000000
11-13 20:24:36.876: INFO/DEBUG(121): 464c9104 afd156e3 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c9108 afd14699 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c910c afd14699 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c9110 afd146f0 /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c9114 802a3448 /system/lib/libdvm.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c9118 802a3448 /system/lib/libdvm.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c911c 0030e960 [heap]
11-13 20:24:36.876: INFO/DEBUG(121): 464c9120 0030e9b0 [heap]
11-13 20:24:36.876: INFO/DEBUG(121): 464c9124 afd146fd /system/lib/libc.so
11-13 20:24:36.876: INFO/DEBUG(121): 464c9128 df002777
11-13 20:24:36.876: INFO/DEBUG(121): 464c912c e3a070ad
11-13 20:24:36.876: INFO/DEBUG(121): #00 464c9130 465117b0 /dev/ashmem/mspace/dalvik-heap/2 (deleted)
11-13 20:24:36.876: INFO/DEBUG(121): 464c9134 80246563 /system/lib/libdvm.so
11-13 20:24:36.876: INFO/DEBUG(121): #01 464c9138 000b4890 [heap]
11-13 20:24:36.876: INFO/DEBUG(121): 464c913c 00000000
11-13 20:24:36.876: INFO/DEBUG(121): 464c9140 00000051
11-13 20:24:36.876: INFO/DEBUG(121): 464c9144 0030e960 [heap]
11-13 20:24:36.876: INFO/DEBUG(121): 464c9148 000b4890 [heap]
11-13 20:24:36.876: INFO/DEBUG(121): 464c914c 46512b88 /dev/ashmem/mspace/dalvik-heap/2 (deleted)
11-13 20:24:36.876: INFO/DEBUG(121): 464c9150 43277fac
11-13 20:24:36.876: INFO/DEBUG(121): 464c9154 802466f5 /system/lib/libdvm.so
I tried to debug a native process using gdb but I only give this message when app crash:Program received signal SIGSTOP, Stopped (signal).Does anyone could help me find more clues about the error?

View 1 Replies View Related

Android :: Troubleshooting Or Dealing With Stack Overflow Errors When Trace Shows Nothing?

Aug 17, 2010

Got a trace like this:
java.lang.StackOverflowError
at android.widget.TextView.onMeasure(TextView.java:5160)
at android.view.View.measure(View.java:8172)
at android.widget.TableRow.getColumnsWidths(TableRow.java:308)
at android.widget.TableLayout.findLargestCells(TableLayout.java:497)
at android.widget.TableLayout.measureVertical(TableLayout.java:462)
at android.widget.TableLayout.onMeasure(TableLayout.java:428)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1012)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:381)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:304)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1012)
at android.widget.LinearLayout.measureHorizontal(LinearLayout.java:696)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:306)
at android.view.View.measure(View.java:8172)
at android.widget.ListView.measureScrapChild(ListView.java:1135)
at android.widget.ListView.measureHeightOfChildren(ListView.java:1200)
at android.widget.ListView.onMeasure(ListView.java:1109)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1012)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:381)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:304)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
at android.view.View.measure(View.java:8172)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:526)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:304)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
at android.view.View.measure(View.java:8172)
at android.view.ViewRoot.performTraversals(ViewRoot.java:805)
at android.view.ViewRoot.handleMessage(ViewRoot.java:1744)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:144)
at android.app.ActivityThread.main(ActivityThread.java:4937)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:521)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
at dalvik.system.NativeStart.main(Native Method) Is there anything that can be done here? I'm getting reports of blank screens and force closes.

View 1 Replies View Related

HTC Incredible :: Contacts Overflow From Gmail Account

May 27, 2010

can anyone help with this? it ported all of my gmail contacts from years and they pop up as suggestions when i try to sms or use other apps that search for contacts. this is incredibly annoying and i really hope i don't have to wipe my phone to fix it. is there any other way?

View 4 Replies View Related

Android :: FPS Using Opengl Es On G1

Jan 27, 2009

I am working on developing a 3d game. I have loaded ms3d model in my project and all texture and everything is working fine. I m not loading any joints.But I am facing two major problems which indeed are related to one thing. 1: I have got FPS problem in my game.Its too low even on G1. 2: When I have touch event to control the game it affects the FPSmore. So plz let me know how to optimize it more because the same game with same code of opengl es is wokring at 45 FPS on Iphone So why its running slow on G1.What is opengl es benchmark for G1 ? Wat can be comparison btwn Iphone and G1 related to hardware acceleration?

View 3 Replies View Related

Android :: OpenGL On 1.6

Oct 11, 2009

Been working with OpenGL a little more recently, and have been noticing pretty bad performance on my G1. Were there any major changes to OpenGL in 1.6 that would change the performance (or made my code incorrect?) on device? As a test, I grabbed the SpriteMethodTest out of Apps-For-Android, and gave it a spin. I had run it a few months ago and noticed pretty decent performance. With a low number of sprites (10-100), every method (Verts, Hardware VBO's, and DrawTex) had easily over 30fps, with drawTex beating out the others. I fired it up on my G1 (recently updated to 1.6), and all 3 methods are giving me performance of around 10-12fps with all methods of OpenGL at 10 sprites. Just for fun, installed the exact same APK on my girlfriends phone, which has yet to be updated to 1.6, and hers shows what I expected to start with, 30-60fps depending on method. So the question is, did anything change in terms of OpenGL, that would make the example code in SpriteMethodTest less than optimal?

View 3 Replies View Related

Android :: Opengl Es 2.0?

Nov 16, 2010

I want ask some questions about Opengl es 2.0?

View 3 Replies View Related

Android : How To Use Png / Jpg In OpenGL ES?

Aug 24, 2010

What is the correct way to save images in png format, if I want to use it in my Android OpenGL ES application as texture?

View 1 Replies View Related

Android :: Bad OpenGL Emulation

Aug 19, 2009

I'm developing a new game and have been having inconsistencies between the device and emulator. The biggest one for me right now is that the elements I draw with an orthographic projection work correctly on the device, but are 1/2 the size on the emulator. I've checked and rechecked the code 100 times and I'm positive I've done it right but am confused as to why I'm seeing that result. I suppose I could go forward doing ALL testing on a device - and I may have to, seeing that the emulator's frame rate is horribly slow - but I was hoping that I could do some of the work on it at least.

View 15 Replies View Related

Android :: OpenGL ES Application

Oct 25, 2010

I am currently trying to develop a game for android in OpenGL ES and I am testing it on my Nexus One. But I have run into some performance problems,and I would like to ask somebody about it,could you help?I currently have a very basic scene - background made of 25 tiles(256x256 texture each), and then a number of textured cubes(128x128 texture for each side of a cube ). However,when I try to display approx. more than 10 cubes, the performance becomes so sluggish that I can't even rotate the scene smoothly. I can't imagine how can I add more objects(player,enemies, all that kind of stuff) when it runs so slowly with 35 objects in total. I mean - games like Raging Thunder 2 probably display hundreds of objects at once(plus they do lots of computations behind the scenes) and they run super- smooth on my nexus one. What am I doing wrong? Could somebody help me please?

View 13 Replies View Related

Android :: Java API For OpenGL ES 2.0?

Aug 25, 2010

I am learning Android development, specifically to eventually do OpengL 2.0 ES on it. So far I have read that the NDK supports Opengl 2.0 ES. However, is there also a Java API for it? If there is a Java API for it, which one is recommended? I know both C++ and Java, so it is not a big deal if I have to use the NDK, but I would prefer to work only in Java if possible and without a big performance hit.

View 1 Replies View Related

Android :: PNG Transparency And OpenGL ES

May 27, 2009

I am rendering this PNG with no transparency just fine: http://n4te.com/temp/test.png However if I try to render this PNG (with transparency) with the exact same code, I just get a white box: http://n4te.com/temp/ball.png

I am loading the PNG into a texture like this: Bitmap bitmap = BitmapFactory.decodeStream(input); int[] temp = new int[1]; gl.glGenTextures(1, temp, 0); textureID = temp[0]; gl.glBindTexture(GL10.GL_TEXTURE_2D, textureID); gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MIN_FILTER, GL10.GL_NEAREST); gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_MAG_FILTER, GL10.GL_NEAREST); // GL_LINEAR for quality. gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S, GL10.GL_CLAMP_TO_EDGE); gl.glTexParameterf(GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_T, GL10.GL_CLAMP_TO_EDGE); GLUtils.texImage2D(GL10.GL_TEXTURE_2D, 0, bitmap, 0); bitmap.recycle();

I am using this blending: gl.glBlendFunc(GL10.GL_SRC_ALPHA, GL10.GL_ONE_MINUS_SRC_ALPHA); How is it possible to render a PNG with transparency in OpenGL ES?

View 7 Replies View Related

Android :: OpenGL And Use Of ByteBuffers

Feb 23, 2010

I'm porting over some software from the iPhone, and the fact that I need to use ByteBuffers for my data structures in order to use OpenGL is killing me. My render loop takes 3ms to actually do the work and render screen, but I do need to perform a ByteBuffer clear / repopulate to update a dynamic texture. The bytebuffer clear, followed by the put() and position(0) to prepare for texture uploading takes about 100ms. This is WAY too slow. Is there a way around using ByteBuffers other than going the NDK route? The texture is 512x256 RGBA. should the ByteBuffer .clear() .put() and .position() be taking 100ms?

View 11 Replies View Related

Android :: OpenGl Drawn Something?

May 10, 2010

glReadPixels is too slow, so I need another way. Without testing object by object, Is there any other way?

View 7 Replies View Related

Android :: GluUnProject - Opengl Bug?

Feb 5, 2010

I'm having problems with gluUnProject. I saw other discussions on this message base regarding this function and they did not solve my problem. When I use GLU.gluUnProject I get values that are close, but not quite right. I'm manually keeping track of my model matrix and I replicate the projection matrix manually. (I have also tried setting the projection matrix to identity and manually incorporating a projection matrix into my model matrix, and I ended up with the same results). I tried using the builtin GLU.gluUnProject function and I also implemented my own based on reading that source and reading the C GLU sources and both seemed to give substantially similar results. So I put together a small demo, trying to keep it as minimal as possible and still get the point across. Either this demo shows a misunderstanding I have of gluUnProject or it shows a bug in the function or opengl projections. Can someone check this over and see if I'm just doing something wrong or if there's a bug that needs to be filed? The files are here: http://www.thenewsh.com/~newsham/unproj/ In particular:

unproj.java - full source to example unproj-debug.apk - resulting apk file unproj - directory with full ant-buildable project unproj.zip - zip of directory

View 7 Replies View Related

Android :: OPenGL - XML Integration

Aug 26, 2010

I'm making a media player application in android where one part of my screen has a animation which is made in OpenGL (ofcourse with Android/JAVA).....So my screen consists of 2 parts:

1) Left hand side consists of all the widgets (using xml).

2) Right hand side consists of the animation made in OpenGL.

I'm able to make the Gui (xml part) and also the animation (opengl). Can i integrate the GUI made in XML file with the animation (made using GLSurfaceview)?

View 1 Replies View Related

Android :: OpenGL ES Libraries

Jul 13, 2010

I looked around for info on this in the group but couldn't find any... so far in my OpenGL programming I've just done everything directly, but I was curious if anyone had written any "wrapper" libraries for it besides min3d. Min3d is great (or is getting there) but it's GPL'd, making it unsuitable for a commercial product (if my understanding of the license is correct).

View 5 Replies View Related

Android :: G1 Support For OpenGL ES 1.1?

Feb 2, 2009

Does anyone know whether the G1 device is capable of supporting OpenGL ES 1.1? Is this something that depends on both the graphics chip and the OS, or is it purely software? If Android/the G1 only supports OpenGL ES 1.0, are there any pieces of the 1.1 spec that are supported?

View 3 Replies View Related

Android :: OpenGL-ES 2.0 Support

Feb 5, 2009

Is there any plan to support OpenGL-ES 2.0 in Android? Is it possible to write a renderer youself based on OpenGL-ES 2.0? In that case, where to start.

View 2 Replies View Related

Android :: OpenGL Textures

Feb 17, 2010

I'm learning OpenGL on my own atm and I have a question about texturing a surface:

I can create a simple polygon like this:

CODE:......

Then I load all of that info into the approriate buffers and draw it to the screen with a call to:

CODE:..

My question:

I'm looking for a good example of how to take an image and texture it to the surface.

View 4 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved