**** BEGIN LOGGING AT Sat Aug 08 02:59:57 2009 Aug 08 04:04:46 doesn't sharedpreferences get shared between activites? Aug 08 04:20:12 frez: yes Aug 08 04:34:24 frez: sharedpreferences is a file-backed object... Aug 08 04:35:13 looks like network is the preferred way to store data in android Aug 08 04:35:39 ? Aug 08 04:48:45 it doesn't get shared it seems Aug 08 04:49:10 not here anyways Aug 08 04:52:12 I tried prefs = getPreferences(0) in my other activity and it didn't look like it got shared Aug 08 04:53:21 oh nevermind Aug 08 05:40:35 hi, i'm trying to develop an app that uses the camera's preview callback Aug 08 05:41:35 but whenever i try to read from the byte[] array in the callback Aug 08 05:41:59 the VM starts throwing out of memory errors all over the place Aug 08 05:42:23 and on top of that, the camera then refuses to stop sending frames, so i have to reboot the device before continuing to debug Aug 08 06:03:00 perihare: hmm, can you show us some relevant code? Aug 08 06:03:14 curious if you are not actually allocating more objects (copying the byte[] array perhaps?)_ Aug 08 06:03:23 i havent worked with the camera personally though Aug 08 06:07:27 well, i actually thought i might be holding the byte[] array for too long Aug 08 06:07:46 so i tried cloning it and passing it off to another thread first, but it didn't really help Aug 08 06:08:06 hold on Aug 08 06:12:47 http://hareit.com/android/ Aug 08 06:13:12 so i have my activity Test that feeds preview frames to a Meter Aug 08 06:13:49 Test has the camera preview view code from the android SDK in it, adds that to its content view Aug 08 06:14:07 and has a textview overlayed on the preview for showing the meter readout Aug 08 06:14:40 anyway, i want to process the live preview from the camera using the preview callback Aug 08 06:14:59 i'm able to add an empty callback fine, or one that just prints a line and leaves Aug 08 06:15:25 but as soon as i touch the byte[] array the VM freaks out and says i'm out of memory Aug 08 06:15:51 so maybe i'm holding reference to it somehow, but i don't think i am Aug 08 06:21:56 working with a raw buffer in java is weird anyway, and i found this bug report that backs that up Aug 08 06:21:59 http://code.google.com/p/android/issues/detail?id=2794 Aug 08 06:22:15 but i must be doing it wrong because barcode scanner etc. can do this Aug 08 07:14:33 okay I'm awake Aug 08 07:14:41 time to restart my 2d engine (again) Aug 08 07:14:47 but this time I aim for efficiency :P Aug 08 07:14:51 reuse objects etc Aug 08 07:15:06 and btw: I love my magic :P Aug 08 07:15:21 monday I'll have mobile internet, currently its only wifi @ home Aug 08 07:28:26 yay, my sapphire came back to life! Aug 08 07:28:34 proof that androids actually like to swim! Aug 08 07:29:59 lol! Aug 08 07:30:17 may I suggest, as a friend, to not attempt that again? :P Aug 08 07:33:59 <_Auron|G1_> heh Aug 08 08:03:45 hey can any1 tell me about c++ on android?...how does it compare Aug 08 08:06:46 google for box2d and NDK Aug 08 08:07:26 someone ported it to ndk, it was alot faster compared to jbox2d BUT he said the interaction between java<>native still produced a noticable 'delay' Aug 08 08:07:58 ok i see Aug 08 08:08:10 im gonna research it a little Aug 08 08:09:02 hmm well Aug 08 08:09:08 for future reference on the problem i had Aug 08 08:09:24 apparently how barcode reader does it is that they only use a previewhandler once Aug 08 08:10:33 when it's called, the preview callback does camera.setPreviewCallback(null); Aug 08 08:10:50 and only after the frame has been processed does it make a new callback Aug 08 08:10:52 weird Aug 08 09:00:05 is it possible to display a progress bar in a non ui thread? Aug 08 11:07:23 Hey, what is the recommended format+resolution for a logo? Aug 08 11:07:27 logo/icon Aug 08 11:11:11 48x48 png with alpha? Aug 08 11:11:20 http://developer.android.com/guide/practices/ui_guidelines/icon_design.html#launcherstructure Aug 08 11:12:15 ah, thanks :) Aug 08 11:16:21 hey guys Aug 08 11:16:28 there is an error in my manifest Aug 08 11:16:38 http://www.pastebin.org/7417 Aug 08 11:16:42 its cmoplaining about line 5 Aug 08 11:16:45 saying that class does not exist Aug 08 11:16:48 but it bloody well does! Aug 08 11:19:09 lowercase boinc? Aug 08 11:19:12 funny class name :) Aug 08 11:20:42 Hi, is there a way to use animated wait-circle? I mean that thing that is e.g. under Windows a sandglass. I want to use it without the normal wait dialog Aug 08 11:21:32 ProgressBar Aug 08 11:21:57 is by default a spinner 'wait circle' Aug 08 11:22:47 deebo: thanks! how can I be _that_ stupid not to find it ... Aug 08 11:34:00 hi, breakpoints set on an inputMethodService seem not to work, is it normal? Aug 08 11:39:49 anyone ^^^ Aug 08 11:39:58 http://www.pastebin.org/7417 complains at line 5 Aug 08 11:40:03 says clas doesnt exist Aug 08 11:40:05 but it does Aug 08 11:46:13 .... Aug 08 11:46:17 haro.. Aug 08 11:46:19 plz help Aug 08 11:50:00 people Aug 08 11:50:01 :@ Aug 08 11:59:07 hey, do you have an idea how i could display mathematical formula in a application? Aug 08 12:08:30 AnyArmstrong: because .boinc is not the class name Aug 08 12:08:38 remove the . Aug 08 12:11:07 _Auron_ are you here ? Aug 08 12:12:47 I currently have 2 threads : the game (processing) thread and the render thread (opengl es) Aug 08 12:13:14 what I do is create a list of things to draw (draw* classes) and then once all game 'states' are processed push them to the opengl es thread for rendering Aug 08 12:13:51 this works well, but prevents optimizations Aug 08 12:14:52 alternative method would be to let a 'draw' method be called in the states (on teh opengl es thread) BUT then I have another problem : since its 2 seperate threads I either have to 'lock' the 'runs' per seconds to FPS OR let my state figure out if it may draw or not Aug 08 12:14:55 meh Aug 08 12:16:29 actuakllly cmas u need the . Aug 08 12:16:46 cant decide on a good method :'( Aug 08 12:20:50 hmm what I could do is let the render thread watch some variable, if its true, it'll run draw() on all states, if not true, sleep till it is true Aug 08 12:21:12 this means it is stilled 'linked' to fps BUT if a state doesnt ask for a rerender, it wont trigger draw()'s :) Aug 08 12:21:31 how does that sound? anyone? :P Aug 08 12:23:07 have you watched the google io talk "writing realtime games on android"? Aug 08 12:25:43 saw the presentation slides (I think) Aug 08 12:26:01 I wrote a simple 'recycle bin' to reuse objects :P Aug 08 12:26:12 since creating objects is evil @ android Aug 08 12:29:03 btw any tips for game programming books/resources, i get the basic principles of real time games but need info and examples on stuff like syncing etc Aug 08 12:29:47 no idea, sry, trying it on myself here :P Aug 08 12:42:43 Can I install any newer version than my preinstalled 1.5 release 1 on my HTC Hero? Aug 08 12:58:07 ok I done it as I said last Aug 08 12:58:10 think it should work :p Aug 08 13:27:45 w00t it rendered a circle ;p Aug 08 13:29:49 hi, anyone here familiar with the Input Method Manager? Aug 08 15:20:08 so apparently Aug 08 15:20:57 TelephonyManager.getNetworkType() can return 4 on the HTC Hero Aug 08 15:21:48 I assume this is HSDPA, but I can't see it in the documentation.. is this a HTC Hero thing only, or will that be the standard? Aug 08 15:24:01 and is there another value for HSUPA? Aug 08 15:24:58 would there be a reason to NOT leave glEnableClientState(GL10.GL_VERTEX_ARRAY) on at all times? Aug 08 15:45:44 can someone tell me how i can get data stored in a mysql database... since the jdbc driver code isn't distributed with android i'm a bit lost Aug 08 15:49:11 shahon: short answer - either use a pure-java library and include the jar, or provide an HTTP wrapper on your server Aug 08 15:49:36 in the meantime, who knows the right way to react to an item in a spinner being selected? Aug 08 16:01:52 facially? sort of like this -> :O Aug 08 16:02:30 (I don't know, is the real answer) Aug 08 16:26:35 hi all Aug 08 16:27:43 hi Aug 08 16:34:39 my way of doing object recycling Aug 08 16:34:40 http://nopaste.me/4815 Aug 08 16:40:57 does that look ok? Aug 08 17:37:19 Hello all! Aug 08 17:57:24 hey guys Aug 08 18:08:08 jasongornall: did you get my message about alertdialog box yesterday? Aug 08 18:08:20 before u disconnect Aug 08 18:08:30 ohh yeah Aug 08 18:08:33 thankyou :) Aug 08 18:08:45 hey guys Aug 08 18:09:01 glad, u did :) Aug 08 18:09:07 is it possible that i can write a service which listens for battery state changes like plugged in charging etc - and then execute an activity based upon that Aug 08 18:10:18 ... Aug 08 18:10:32 is it possible to make a spinner popup without actually adding it to the contextview? Aug 08 18:10:46 like I want to have it on a button pressed a box comes up to choose items Aug 08 18:10:53 I believe a spinner is the best way to do that? Aug 08 18:15:19 ArmyAndy: maybe it's a broadcast for that? Aug 08 18:17:39 ArmyAndy: android.intent.action.BATTERY_CHANGED? Aug 08 18:25:07 xavd ? Aug 08 18:28:30 frez so how do i right a service which just sits there Aug 08 18:28:32 and then reacts to it Aug 08 18:29:01 i know how i would write an application like ana ctivity to do it Aug 08 18:29:31 but its a bit diff if the thing has no Aug 08 18:29:44 how do i right a service which intercepts those broadcasts then Aug 08 18:29:54 cos its a bit diff to having an acitivity in the foreground doing it Aug 08 18:33:31 anyone out there wanna help me out? Aug 08 18:50:58 http://www.break.com/index/cool-nes-synth-music-application.html Aug 08 18:51:03 i want that for android :-| Aug 08 18:51:12 can someone explain to me how to create a contextmenu? Aug 08 18:51:19 I have tried over 5 tutorials and none of them work Aug 08 18:55:12 jasongornall: on a listview? just registerForContextMenu(list) and then handle on something something context menu :) Aug 08 18:55:46 android.git.kernel.org is your friend.... Aug 08 18:59:11 Is there a way to disable the screen timeout while I'm plugged into USB? Or do I have to do it manually? just gets a little annoying having to unlock it every now and then while developing Aug 08 19:00:48 savid: yes, see developer settings under applications or whatever Aug 08 19:01:38 jasta, ahh thanks.. I thought there was a setting for that, just couldn't find it :-P Aug 08 19:02:47 jasta Aug 08 19:02:51 can I do that to a textview? Aug 08 19:03:04 jasongornall: sure, but don't. Aug 08 19:03:12 lol I am just testing the menu :p Aug 08 19:03:16 textview already has a context menu, it prompts for input method Aug 08 19:03:17 before I add it to my main program Aug 08 19:03:24 just don't. Aug 08 19:03:24 ahh Aug 08 19:03:29 what should I test it on then Aug 08 19:04:09 add context menus to lists Aug 08 19:05:59 ahhh Aug 08 19:06:04 so does it run the menu Aug 08 19:06:10 for each cell on a listview? Aug 08 19:06:21 uhm, something liek that Aug 08 19:07:20 yeah it works! Aug 08 19:07:22 thanksyou Aug 08 19:07:23 :D Aug 08 19:08:34 is there a way to know which item from the listview was clicked on Aug 08 19:09:26 what do you think? Aug 08 19:12:49 well yeah there has to be Aug 08 19:12:53 jasongornall: have you done the notepad exercises? Aug 08 19:14:08 Notepad Exercise 2 objective: "How to create a context menu" Aug 08 19:17:18 sweet Aug 08 19:17:21 just went through it Aug 08 19:17:24 AdapterContextMenuInfo info = (AdapterContextMenuInfo) item.getMenuInfo(); Aug 08 19:17:32 info.id Aug 08 19:19:24 I have a sprite that's loaded using context.getResources().getDrawable(), and I'm rotating it using canvas.rotate(). How do I make it so that the drawable is antialiased, so the edges look more smooth when rotating? Aug 08 19:48:35 SO, how do i write a service which just sits in the background and responds whenever a certain broadcast is found?!?!?!? cos it seems different to an activity?! Aug 08 19:51:05 SO, how do i write a service which just sits in the background and responds whenever a certain broadcast is found?!?!?!? cos it seems different to an activity?! Aug 08 21:16:27 hi is it possible to make a service that runs even after restarting the fone automatically? Aug 08 21:21:25 ... Aug 08 21:23:55 anyone!? Aug 08 21:27:21 ... Aug 08 21:28:15 is there any way to add codecs to the media engine on android ? like … compiling libtheora ? Aug 08 21:29:09 no dnt think so Aug 08 21:30:35 the media framework is closed'ish i think Aug 08 21:31:01 hopefully they add more support later Aug 08 21:31:23 tho it already supports generic mpeg4, no info on containers etc tho Aug 08 21:33:11 so does anyone no can I make a service that starts everytime the fone is turned on Aug 08 22:05:57 is there a way to show a menu on click Aug 08 22:06:00 instead of click hold? Aug 08 22:11:51 deebo: vorbis is there :) but theora would be nice, especially since its appropriate for low-powered devices, like some of the other on2 codecs. Aug 08 22:13:14 erlehmann: the media support is really shitty for video anyhow Aug 08 22:17:02 is there a way to show a menu on click Aug 08 22:17:02 [6:06pm] jasongornall: instead of click hold? Aug 08 22:17:05 :) Aug 08 22:29:41 Hello Aug 08 22:30:05 anyon here? Aug 08 22:33:31 I love when people do that... Aug 08 22:38:23 ask2ask protocol has serious overhead Aug 08 22:46:22 jason maybe try opening a dialog with a when you click a list view item? mess around with that to see if it can do what you want Aug 08 23:32:23 can anyone tell me the name of the broadcast for when u plug in ur fone Aug 08 23:34:36 anyone know how to programatically launch a contextmenu Aug 08 23:44:16 Hi Aug 08 23:44:24 I've a little question... :D Aug 08 23:58:08 So... I've my response :p Thanks ^^ Aug 09 00:18:26 any ideas how this can happen? "... getNetworkLocation(): Returning cache location with accuracy -1.0" It's causing strange behavior. Aug 09 00:18:41 I don' see any documentation about negative accuracy Aug 09 00:19:13 maybe it means no accuracy available -> no lock at all? Aug 09 00:19:31 I believe it's supposed to return 0.0 if that's the case Aug 09 00:24:11 what class is that method in Aug 09 00:25:58 getNetworkLocation() is some inaccessible method called for location-stuff, you can see it being used in logcat Aug 09 00:27:06 ah, i just thought about looking it up in the sources Aug 09 00:31:16 apparently it means the provider is temporarily unavailable Aug 09 00:38:53 resetting the unit solved that issue, but that's not good Aug 09 00:42:54 hmm no streetview in the maps app? Aug 09 00:48:40 its there, i think you have to dig for it tho Aug 09 00:49:13 deebo: long-press on a map location Aug 09 00:49:16 anywhere on map Aug 09 00:50:20 jsharkey: ah, thanks Aug 09 00:51:29 compass mode is so cool heh Aug 09 00:51:39 I use google maps in my app, and use MyLocationOverlay to show where i am. But is there a way to keep my pos centered? Now it moved the map only when i am about to leave it kinda Aug 09 00:53:31 override onLocationChanged Aug 09 00:53:47 add mapView.getController().animateTo(location) Aug 09 00:53:58 thanks! Aug 09 01:39:30 hmpf, arent there any proper video players for android yet Aug 09 01:39:46 the 'video player' app from the market doesnt keep sync, fps seems to randomly fluctuate Aug 09 01:39:56 act1 player doesnt keep the aspect ratio **** ENDING LOGGING AT Sun Aug 09 02:59:57 2009