If AndroidBitmap_lockPixels failed, the function shouldn't continue.
Perhaps it really failed, and you just didn't pay attention to the
log.
alan: insofar as I can tell. Here are the last few pos values that I
am modifying right before the crash (obtained through log printing):
Array: 260119 260118 260117
Array: 261143 261142 261141
Array: 262146 262145 262144
Array: 263170 263169 263168
Array: 264194 264193 264192
Array: 265218 265217 265216
Array: 266242 266241 266240 (the apparently faulty address)
(*crash* )
signal 11 (SIGSEGV), fault addr 42a4d00a
r0 00000020 r1 00000000 r2 00000000 r3 42a4d008
r4 00000004 r5 0000aa50 r6 00041000 r7 80836dfd
r8 00000000 r9 00000000 10 000000a0 fp 00000000
ip 0000000f sp bea67820 lr 80840ea5 pc 80901296 cpsr 00000030
Not sure if that's helpful. It's all hex to me. I did find some math
online that suggested the pixel memory size is equivalent to stride *
height of the image--for me that's 262144. Maybe there are some buffer
pixels involved as well, or maybe it's all gibberish, but it's a
number awfully close to where I am crashing.
Igor: good catch. I added a return; statement within the loop. The
code however continues to function (i.e. lockPixels doesn't fail).
--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en.