OpenGL ES problem: Trouble loading a bitmap texture (comes out blue)

by Jon Colverson » Thu, 05 Mar 2009 03:34:30 GMT


Sponsored Links
 I don't understand why you're trying to copy the texture from a Bitmap
into an IntBuffer before setting it. Why not use GLUtils.texImage2D to
load the Bitmap directly?

--
Jon

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



Other Threads

1. ClassNotFoundException in productions

Hi,

I have an application that's on Android Market with >10,000 users.
Every once in while (once or twice a week), I am getting a
ClassNotFoundException on the Market Developer Console for my main
activity:


java.lang.RuntimeException: Unable to instantiate activity
ComponentInfo{com.mycompany.myapp/com.mycompany.myapp.MainActivity}:
java.lang.ClassNotFoundException: com.mycompany.myapp.MainActivity in
loader dalvik.system.PathClassLoader[/mnt/asec/com.mycompany.myapp-1/
pkg.apk]
at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2757)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:
2866)
at android.app.ActivityThread.access$2300(ActivityThread.java:140)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:
2181)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:143)
at android.app.ActivityThread.main(ActivityThread.java:5097)
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)
Caused by: java.lang.ClassNotFoundException:
com.mycompany.myapp.MainActivity in loader
dalvik.system.PathClassLoader[/mnt/asec/com.mycompany.myapp-1/pkg.apk]
at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:243)
at java.lang.ClassLoader.loadClass(ClassLoader.java:573)
at java.lang.ClassLoader.loadClass(ClassLoader.java:532)
at android.app.Instrumentation.newActivity(Instrumentation.java:1034)
at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2749)
... 11 more


Note that this application is in production and used by > 10,000
people and MainActivity is the very first activity during startup.
This error happens very rarely, but yet it happens. I couldn't
reproduce it on my developer phone nor the emulator, so I ended up
adding a default application that's extended from Application and
called before my main activity, but this time I got the same exception
for my Application class:

java.lang.RuntimeException: Unable to instantiate application
com.mycompany.myapp.App: java.lang.ClassNotFoundException:
com.mycompany.myapp.App in loader dalvik.system.PathClassLoader[/mnt/
asec/com.mycompany.myapp-1/pkg.apk]
at android.app.ActivityThread
$PackageInfo.makeApplication(ActivityThread.java:649)
at
android.app.ActivityThread.handleBindApplication(ActivityThread.java:
4232)
at android.app.ActivityThread.access$3000(ActivityThread.java:125)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:
2071)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:123)
at android.app.ActivityThread.main(ActivityThread.java:4627)
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:876)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:634)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.ClassNotFoundException: com.mycompany.myapp.App
in loader dalvik.system.PathClassLoader[/mnt/asec/
com.mycompany.myapp-1/pkg.apk]
at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:243)
at java.lang.ClassLoader.loadClass(ClassLoader.java:573)
at java.lang.ClassLoader.loadClass(ClassLoader.java:532)
at android.app.Instrumentation.newApplication(Instrumentation.java:
942)
at android.app.ActivityThread
$PackageInfo.makeApplication(ActivityThread.java:644)
... 11 more


This application is installed to SD Card by default and my guess is
that it might be SD Card related, so I tried to mount/unmount my SD
Card to reproduce it and still no luck. I am really puzzled at this
point and trying to find out if anyone has suggestions.
ClassNotFoundException is thrown when the app package does not contain
a required class, but that's not the case for my app. Please help :)


Thank you,


-Vega



-- 

2. video playing error

when ever i tried to play video from my asset folder .i get the
folling msg on logcat ...
but nothing is displayed .can any explain me how to solve this
peoblem..
thanx in advance




W/AudioFlinger(   30): write blocked for 70 msecs, 588 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 69 msecs, 615 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 70 msecs, 642 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 78 msecs, 672 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 85 msecs, 698 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 71 msecs, 726 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 78 msecs, 752 delayed writes,
thread 0x
b388
W/AudioFlinger(   30): write blocked for 71 msecs, 786 delayed writes,
thread 0x
b388

-- 

3. Debugging "deep" crashes

4. Conflicting advice on how to setup a test project

5. answer to android

6. blocking non market app programatically

7. HD Family Club -- download HD DVD Movies with rapidshare, megaupload, torrent link ... 100% free