Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - kkl

Pages: 1 ... 14 15 [16] 17 18 ... 20
226
Support / Re: Live Wallpaper uisng JPCT
« on: July 18, 2013, 05:46:45 pm »
Android does not provide API for opengl live wallpaper . You will need to create the entire rendering thread, EGL context and etc for opengl from scratch. Fortunately, some people have done it, eg https://github.com/GLWallpaperService/GLWallpaperService. They have simple tutorial on how to use it. Then, you may implement JPCT-AE to that, similar way to GLSurfaceView. There are alot more libraries that support opengl wallpaper service out there. For basic about the wallpaper service, check out the android SDK sample project.

227
Support / Re: Strange looking preference activity in livewallpaper
« on: July 18, 2013, 05:36:31 pm »
Sorry for replying late. Was busy these few days.

I tested out with eclipse MAT and both cases (disposing framebuffer and other stuff at engine's onDestroy() and the end of rendering thread respectively) seem to be almost same. Still new in eclipse MAT, BTW.

However, the memory status in android seems to be different though.
1. Dispose at engine's onDestroy() with jpct-ae beta: Memory can go as low as 80-90MB.
2. Dispose at the end of rendering thread: Memory gets low but maintains around 150MB.

*Both cases are tested when live wallpaper is set to phone and home button is pressed at wallpaper preference activity.

BTW, why is it a bad idea to dispose at rendering thread?

228
Support / Re: Strange looking preference activity in livewallpaper
« on: July 13, 2013, 12:14:56 pm »
When GLRenderer is disposed, it is disposed on Main Thread (GLRenderer disposed with id 3 on Thread[main,5,main]), but when it is created, it's in GLThread (GLRenderer created with id 4 on Thread[GLThread 19049,5,main]). Does this cause the gl pointing to the wrong resources and dispose the wrong one?

229
Support / Re: Strange looking preference activity in livewallpaper
« on: July 13, 2013, 12:06:52 pm »
I can't tell exactly what causes that, but I'm guessing VBOs and other objects are lost due to gl context changed and not being disposed. Since the WallpaperService object will stay as long as the livewallpaper is set to the phone, the lost VBOs or other objects are not be garbage collected within the WallpaperService object, IMHO.

Yes, I believe I did dispose the framebuffer.

Just in case, here's the debug log I recorded.
Code: [Select]
07-13 17:52:26.555: V/Kision(2283): Preference onPause(): com.kisionlab.tapleaves.WallpaperPreferenceActivity@4307aad8
07-13 17:52:26.890: D/GLWallpaperService(2283): onSurfaceDestroyed()
07-13 17:52:26.905: I/jPCT-AE(2283): [ 1373709146911 ] - WARNING: Unable to dispose gl related resources because the current context has changed!
07-13 17:52:26.905: I/jPCT-AE(2283): Renderer disposed!
07-13 17:52:26.905: I/jPCT-AE(2283): GLRenderer disposed with id 3 on Thread[main,5,main]
07-13 17:52:26.905: V/Kision(2283): onUniverseDestroyed! com.kisionlab.tapleaves.SceneSettingRenderer@42413898
07-13 17:52:26.905: V/Kision(2283): Engine onDestroy(): com.kisionlab.tapleaves.WallpaperService$WallpaperEngine@431b5b50 true
07-13 17:52:26.905: W/WallpaperService(2283): Ignoring updateSurface: destroyed
07-13 17:52:27.090: V/WallpaperService(2283): Display Width=480   Height=800
07-13 17:52:27.090: V/Kision(2283): Engine onResume(): com.kisionlab.tapleaves.WallpaperService$WallpaperEngine@42390d30 false
07-13 17:52:27.120: V/Kision(2283): onUniverseCreated! com.kisionlab.tapleaves.SceneSettingRenderer@42393538
07-13 17:52:27.120: V/Kision(2283): onUniverseChanged! com.kisionlab.tapleaves.SceneSettingRenderer@42393538
07-13 17:52:27.120: I/jPCT-AE(2283): Visibility lists disposed!
07-13 17:52:27.120: I/jPCT-AE(2283): [ 1373709147129 ] - WARNING: Unable to dispose gl related resources because the current context has changed!
07-13 17:52:27.120: I/jPCT-AE(2283): Renderer disposed!
07-13 17:52:27.125: I/jPCT-AE(2283): GLRenderer disposed with id 2 on Thread[GLThread 19049,5,main]
07-13 17:52:27.125: I/jPCT-AE(2283): GLRenderer created with id 4 on Thread[GLThread 19049,5,main]
07-13 17:52:27.125: I/jPCT-AE(2283): GL context is 1131742352
07-13 17:52:27.125: I/jPCT-AE(2283): OpenGL vendor:     ARM
07-13 17:52:27.125: I/jPCT-AE(2283): OpenGL renderer:   Mali-400 MP
07-13 17:52:27.125: I/jPCT-AE(2283): OpenGL version:    OpenGL ES-CM 1.1
07-13 17:52:27.125: I/jPCT-AE(2283): OpenGL renderer initialized (using 2/8 texture stages)
07-13 17:52:27.130: I/jPCT-AE(2283): Allocating native memory for 64*64 texture(true/false/false/false/): 16384 bytes!
07-13 17:52:27.135: I/jPCT-AE(2283): New texture's id is: 9
07-13 17:52:27.135: I/jPCT-AE(2283): New texture uploaded: com.threed.jpct.Texture@4320c0e0 in thread Thread[GLThread 19049,5,main]
07-13 17:52:27.135: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.135: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.140: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.140: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.140: I/jPCT-AE(2283): Allocating native memory for 128*128 texture(true/false/false/false/): 65536 bytes!
07-13 17:52:27.145: I/jPCT-AE(2283): New texture's id is: 10
07-13 17:52:27.145: I/jPCT-AE(2283): New texture uploaded: com.threed.jpct.Texture@423857f8 in thread Thread[GLThread 19049,5,main]
07-13 17:52:27.145: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.145: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.150: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.150: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.150: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.150: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.150: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.150: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.150: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.150: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.150: I/jPCT-AE(2283): Allocating native memory for 1024*1024 texture(true/false/false/false/): 4194304 bytes!
07-13 17:52:27.190: D/dalvikvm(2283): GC_FOR_ALLOC freed 8988K, 32% free 20870K/30535K, paused 40ms, total 40ms
07-13 17:52:27.195: I/dalvikvm-heap(2283): Grow heap (frag case) to 25.015MB for 4194320-byte allocation
07-13 17:52:27.235: D/dalvikvm(2283): GC_CONCURRENT freed 876K, 22% free 24089K/30535K, paused 12ms+4ms, total 41ms
07-13 17:52:27.235: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 26ms
07-13 17:52:27.260: D/dalvikvm(2283): GC_FOR_ALLOC freed <1K, 22% free 24089K/30535K, paused 23ms, total 23ms
07-13 17:52:27.260: I/dalvikvm-heap(2283): Grow heap (frag case) to 28.160MB for 4194320-byte allocation
07-13 17:52:27.260: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 55ms
07-13 17:52:27.305: D/dalvikvm(2283): GC_FOR_ALLOC freed 0K, 8% free 28185K/30535K, paused 41ms, total 41ms
07-13 17:52:27.385: I/jPCT-AE(2283): New texture's id is: 11
07-13 17:52:27.385: D/AbsListView(2283): [unregisterDoubleTapMotionListener]
07-13 17:52:27.385: I/MotionRecognitionManager(2283):   .unregisterListener : / listener count = 0->0, ubvf 9budiwrd5ordgfl5BakTrklMrfo$,@,+-.ebb(
07-13 17:52:27.400: I/jPCT-AE(2283): New texture uploaded: com.threed.jpct.Texture@423a4488 in thread Thread[GLThread 19049,5,main]
07-13 17:52:27.400: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.400: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.400: I/jPCT-AE(2283): Allocating native memory for 1024*1024 texture(true/false/false/false/): 4194304 bytes!
07-13 17:52:27.420: D/dalvikvm(2283): GC_CONCURRENT freed 14K, 8% free 28175K/30535K, paused 72ms+4ms, total 115ms
07-13 17:52:27.420: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 19ms
07-13 17:52:27.440: D/dalvikvm(2283): GC_FOR_ALLOC freed 8192K, 35% free 19983K/30535K, paused 22ms, total 22ms
07-13 17:52:27.445: I/dalvikvm-heap(2283): Grow heap (frag case) to 24.150MB for 4194320-byte allocation
07-13 17:52:27.465: D/dalvikvm(2283): GC_FOR_ALLOC freed 0K, 22% free 24079K/30535K, paused 24ms, total 24ms
07-13 17:52:27.490: D/dalvikvm(2283): GC_FOR_ALLOC freed 0K, 22% free 24079K/30535K, paused 21ms, total 21ms
07-13 17:52:27.490: I/dalvikvm-heap(2283): Grow heap (frag case) to 28.150MB for 4194320-byte allocation
07-13 17:52:27.680: D/dalvikvm(2283): GC_CONCURRENT freed 0K, 8% free 28175K/30535K, paused 154ms+5ms, total 189ms
07-13 17:52:27.680: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 36ms
07-13 17:52:27.680: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 36ms
07-13 17:52:27.680: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 37ms
07-13 17:52:27.680: D/dalvikvm(2283): WAIT_FOR_CONCURRENT_GC blocked 37ms
07-13 17:52:27.680: V/Kision(2283): Preference onStop(): com.kisionlab.tapleaves.WallpaperPreferenceActivity@4307aad8
07-13 17:52:27.685: V/Kision(2283): Preference onDestroy(): com.kisionlab.tapleaves.WallpaperPreferenceActivity@4307aad8
07-13 17:52:27.695: I/jPCT-AE(2283): New texture's id is: 12
07-13 17:52:27.710: I/jPCT-AE(2283): New texture uploaded: com.threed.jpct.Texture@4239e220 in thread Thread[GLThread 19049,5,main]
07-13 17:52:27.710: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.710: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.710: I/jPCT-AE(2283): Allocating native memory for 8*8 texture(true/false/false/false/): 256 bytes!
07-13 17:52:27.710: I/jPCT-AE(2283): New texture's id is: 13
07-13 17:52:27.710: I/jPCT-AE(2283): New texture uploaded: com.threed.jpct.Texture@431ca698 in thread Thread[GLThread 19049,5,main]
07-13 17:52:27.710: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.710: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): Allocating native memory for 64*64 texture(true/false/false/false/): 16384 bytes!
07-13 17:52:27.715: I/jPCT-AE(2283): New texture's id is: 14
07-13 17:52:27.715: I/jPCT-AE(2283): New texture uploaded: com.threed.jpct.Texture@431d4720 in thread Thread[GLThread 19049,5,main]
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.715: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.715: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.720: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.720: I/jPCT-AE(2283): Creating buffers...
07-13 17:52:27.720: I/jPCT-AE(2283): OpenGL context has changed(2)...recovering for renderer 4/2!
07-13 17:52:27.720: I/jPCT-AE(2283): Creating buffers...

The log above is made based on this test case:
1. Open preference activity while live wallpaper is set to phone.
2. Press home button

230
Support / Re: Strange looking preference activity in livewallpaper
« on: July 12, 2013, 06:07:49 pm »
Hi Egon,

Thanx for the update. I tried the beta version with the fix, it seems like there is memory leak in live wallpaper.

231
Support / Re: Strange looking preference activity in livewallpaper
« on: June 24, 2013, 04:24:40 pm »
Yes, I tried it before. The memory seemed to leak alot without disposing the framebuffer.

Totally agree with the onSurfaceDestroy thingy. I was expecting that it should work accordingly too. Not sure if Android wallpaper has been designed in a too sophisticated way or it's just simply badly made. *fry squinting*

BTW, I made a few hacks into the existing GLWallpaperService to call another custom surfaceDestroy() method after the end of GLThread loop. It seems to work well now, but I'm still not sure if it is pointing the right context to dispose all objects correctly. The memory seems to leak but only till a limit. I'll continue to analyze it if it's workable, but meanwhile I would still love to hear other better alternatives.


232
Support / Re: Strange looking preference activity in livewallpaper
« on: June 24, 2013, 09:30:13 am »
It's still the same. I tried to free the vbos before engine onDestroy() too, but no luck on that.

Here's the log output if you need it for reference:
Code: [Select]
06-24 15:14:36.465: D/GLWallpaperService(16519): onSurfaceDestroyed()
06-24 15:14:36.465: I/jPCT-AE(16519): Unloaded texture: 6
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 4
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 3
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 1
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 5
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 7
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 2
06-24 15:14:36.470: I/jPCT-AE(16519): Unloaded texture: 8
06-24 15:14:36.470: I/jPCT-AE(16519): All texture data unloaded from gpu!
06-24 15:14:36.470: I/jPCT-AE(16519): Disposing VBOs!
06-24 15:14:36.475: I/jPCT-AE(16519): Renderer disposed!
06-24 15:14:36.475: I/jPCT-AE(16519): GLRenderer disposed with id 4 on Thread[main,5,main]
06-24 15:14:36.475: I/jPCT-AE(16519): Memory usage before compacting: 29218 KB used out of 31431 KB. Max. memory available to the VM is 49152 KB.
06-24 15:14:36.475: D/dalvikvm(16519): WAIT_FOR_CONCURRENT_GC blocked 0ms
06-24 15:14:36.555: D/AbsListView(16519): [unregisterDoubleTapMotionListener]
06-24 15:14:36.560: D/dalvikvm(16519): GC_EXPLICIT freed 17042K, 62% free 12177K/31431K, paused 10ms+13ms, total 84ms
06-24 15:14:36.570: I/MotionRecognitionManager(16519):   .unregisterListener : / listener count = 0->0, ubvf 9budiwrd5ordgfl5BakTrklMrfo$,@,)(b(d)8
06-24 15:14:36.570: D/dalvikvm(16519): WAIT_FOR_CONCURRENT_GC blocked 0ms
06-24 15:14:36.635: D/dalvikvm(16519): GC_EXPLICIT freed 922K, 65% free 11256K/31431K, paused 2ms+3ms, total 64ms
06-24 15:14:36.785: I/jPCT-AE(16519): Memory usage after compacting: 11256 KB used out of 31431 KB. Max. memory available to the VM is 49152 KB.
06-24 15:14:36.790: V/Kision(16519): Engine onDestroy(): com.kision.tapleaves.WallpaperService$WallpaperEngine@41f068b0 true
06-24 15:14:36.790: W/WallpaperService(16519): Ignoring updateSurface: destroyed
06-24 15:14:36.810: V/Kision(16519): Service onDestroy(): com.kision.tapleaves.WallpaperService@41fb3a90
06-24 15:14:36.850: V/Kision(16519): Preference onDestroy(): com.kision.tapleaves.WallpaperPreferenceActivity@420344a8


IMHO, the gl context is switched to preference activity context when wallpaper settings show up. While the activity is active and home button is clicked, renderer is trying delete vbos using preference activity context. May be this causes the issue, presumably. I don't quite know how jPCT retains gl context, may be I can find some workarounds if I know better of it. Would love to listen to your suggestion.

233
Support / Re: Strange looking preference activity in livewallpaper
« on: June 23, 2013, 04:44:28 pm »
Hi Egon,

Does the log output look normal? I tried to the force finish the preference activity when the wallpaper preview called onDestroyed(), but still the preference activity called the onDestroy() after engine is destroyed. I've seen some cool wallpapers have been made with jPCT with no problem with preference activity. Have you encountered any of such issue with them before? 

234
Support / Re: Strange looking preference activity in livewallpaper
« on: June 21, 2013, 07:52:02 am »
Here's the log after home button is pressed while preference activity is visible.

Code: [Select]
06-21 13:49:17.093: D/GLWallpaperService(4406): onSurfaceDestroyed()
06-21 13:49:17.098: V/Kision(4406): Engine onDestroy(): com.kision.tapleaves.WallpaperService$WallpaperEngine@41a67e40 true
06-21 13:49:17.098: W/WallpaperService(4406): Ignoring updateSurface: destroyed
06-21 13:49:17.098: I/jPCT-AE(4406): Unloaded texture: 1
06-21 13:49:17.098: I/jPCT-AE(4406): Unloaded texture: 6
06-21 13:49:17.098: I/jPCT-AE(4406): Unloaded texture: 5
06-21 13:49:17.098: I/jPCT-AE(4406): Unloaded texture: 2
06-21 13:49:17.103: I/jPCT-AE(4406): Unloaded texture: 3
06-21 13:49:17.103: I/jPCT-AE(4406): Unloaded texture: 7
06-21 13:49:17.103: I/jPCT-AE(4406): Unloaded texture: 8
06-21 13:49:17.103: I/jPCT-AE(4406): Unloaded texture: 4
06-21 13:49:17.103: I/jPCT-AE(4406): Unloaded texture: 9
06-21 13:49:17.103: I/jPCT-AE(4406): All texture data unloaded from gpu!
06-21 13:49:17.103: I/jPCT-AE(4406): Disposing VBOs!
06-21 13:49:17.108: I/jPCT-AE(4406): Renderer disposed!
06-21 13:49:17.108: I/jPCT-AE(4406): GLRenderer disposed with id 4 on Thread[main,5,main]
06-21 13:49:17.108: I/jPCT-AE(4406): Memory usage before compacting: 28974 KB used out of 31431 KB. Max. memory available to the VM is 49152 KB.
06-21 13:49:17.108: D/dalvikvm(4406): WAIT_FOR_CONCURRENT_GC blocked 0ms
06-21 13:49:17.163: D/dalvikvm(4406): GC_EXPLICIT freed 16708K, 61% free 12267K/31431K, paused 2ms+9ms, total 54ms
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'border1'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'border2'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leaf1'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leaf2'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leaf3'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leaf4'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leavesGroup1'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leavesGroup2'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leavesGroup3'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leavesGroup4'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'leavesGroup5'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'shadow1'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'shadow2'
06-21 13:49:17.163: I/jPCT-AE(4406): VBO disposed for object 'shadow3'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'shadow4'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'shadow5'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'shadow6'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'shadow7'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'BUTT08_jPCT188'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'BUTT08_jPCT188'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'BUTT07_jPCT189'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'BUTT07_jPCT189'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'BUTT09_jPCT187'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'object193'
06-21 13:49:17.168: I/jPCT-AE(4406): VBO disposed for object 'object193'
06-21 13:49:17.173: I/jPCT-AE(4406): VBO disposed for object 'object194'
06-21 13:49:17.173: I/jPCT-AE(4406): VBO disposed for object 'object194'
06-21 13:49:17.173: I/jPCT-AE(4406): VBO disposed for object 'object195'
06-21 13:49:17.173: I/jPCT-AE(4406): VBO disposed for object 'object197'
06-21 13:49:17.173: I/jPCT-AE(4406): VBO disposed for object 'object197'
06-21 13:49:17.173: I/jPCT-AE(4406): VBO disposed for object 'object198'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object198'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object199'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object201'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object201'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object202'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object202'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object203'
06-21 13:49:17.178: I/jPCT-AE(4406): VBO disposed for object 'object205'
06-21 13:49:17.178: D/dalvikvm(4406): WAIT_FOR_CONCURRENT_GC blocked 0ms
06-21 13:49:17.183: I/jPCT-AE(4406): VBO disposed for object 'object205'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object206'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object206'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object207'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object209'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object209'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object210'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object210'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object211'
06-21 13:49:17.188: I/jPCT-AE(4406): VBO disposed for object 'object214'
06-21 13:49:17.193: I/jPCT-AE(4406): VBO disposed for object 'object215'
06-21 13:49:17.193: D/AbsListView(4406): [unregisterDoubleTapMotionListener]
06-21 13:49:17.193: I/MotionRecognitionManager(4406):   .unregisterListener : / listener count = 0->0, ubvf 9budiwrd5ordgfl5BakTrklMrfo$,@,*e/a:d8
06-21 13:49:17.238: D/dalvikvm(4406): GC_EXPLICIT freed 802K, 64% free 11478K/31431K, paused 14ms+5ms, total 55ms
06-21 13:49:17.388: I/jPCT-AE(4406): Memory usage after compacting: 11479 KB used out of 31431 KB. Max. memory available to the VM is 49152 KB.
06-21 13:49:17.403: V/Kision(4406): Service onDestroy(): com.kision.tapleaves.WallpaperService@42080ce8
06-21 13:49:17.593: V/Kision(4406): Preference onDestroy(): com.kision.tapleaves.WallpaperPreferenceActivity@41a038d8


235
Support / Re: Strange looking preference activity in livewallpaper
« on: June 21, 2013, 05:54:22 am »
Hi Egon,

Sorry to bother you again on this case. I got another issue with preference activity. If I open the preference activity in preview wallpaper, then press the home button, the textures in preference activity are gone again.

This is the flow I can observe from the case above:
1. Preference activity opened
2. Engine paused
3. Home button pressed
4. Engine destroyed
5. Preference activity destroyed

Everything related to gl is disposed at engine's onDestroy(). Can it be that JPCT disposes objects using different context after preference context shows up and takes over gl context? This context thing is really pain in the a**. I have been debugging for few days solely on this.

236
Support / Re: child transformation before and after addParent
« on: June 17, 2013, 06:02:33 am »
Yea, my object has rotation pivot. Anyway,  I finally made it work by editing your code!

Code: [Select]
Matrix m = new Matrix(leaf.getRotationMatrix());
m = m.invert();

SimpleVector t = leaf.getRotationPivot();
Matrix bm = butterfly.getRotationMatrix();
bm.translate(-t.x, -t.y, -t.z);
bm.matMul(m);
bm.translate(t);

SimpleVector offset = butterfly.getTranslation().calcSub(leaf.getTranslation());
offset.matMul(m);

butterfly.clearTranslation();
butterfly.translate(offset);

leaf.addChild(butterfly);


Those who need the same transformation may refer to this code.

BTW Egon, thanx for the code. It was really helpful.

237
Support / Re: child transformation before and after addParent
« on: June 14, 2013, 04:17:36 am »
I tried this:

Code: [Select]
SimpleVector vc = butterfly.getTranslation();
SimpleVector vp = leaf.getTranslation();
SimpleVector vr = new SimpleVector();
vr.x = (vc.x - vp.x);
vr.y = (vc.y - vp.y);
vr.z = (vc.z - vp.z);
butterfly.clearTranslation();
butterfly.translate(vr);
Matrix rm = butterfly.getRotationMatrix();
rm.matMul(leaf.getRotationMatrix().invert3x3());
butterfly.setRotationMatrix(rm);
leaf.addChild(butterfly);

but no luck. The location after adding parent is incorrect. 

238
Support / Re: Set 3ds rotation pivot from Blender for JPCT use
« on: June 13, 2013, 10:42:55 am »
I tried to figure the way in Blender, it seems like it's not exporting the rotation pivot. Do we need Bones for the rotation pivot?

239
Support / child transformation before and after addParent
« on: June 13, 2013, 10:40:31 am »
Hi Egon,

How do we keep the current object world transformation after calling addParent()?

Say,
1. A butterfly flies toward a leaf
2. Butterfly stops at leaf
3. Butterfly addParent(leaf)
4. The butterfly follows the leaf tranformation right at where it stops.

I'd checked this http://www.jpct.net/forum2/index.php/topic,2011.0.html, but the post mentions about removing parent only.
 

240
Support / Re: Set 3ds rotation pivot from Blender for JPCT use
« on: June 05, 2013, 03:44:44 am »
Yes, I did.

 I guess setting the pivot to 3D cursor doesn't save the rotation pivot to 3ds. If the 3ds contains the pivot, it should print out something like "Setting rotation pivot of object........" in JPCT log, isn't it?

How to set rotation pivot and to be saved in 3ds in Blender?

Pages: 1 ... 14 15 [16] 17 18 ... 20