<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Sergi &#38; Replace</title>
	<atom:link href="http://sergiandreplace.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://sergiandreplace.com</link>
	<description>¡Mira, mamá! ¡Salgo en Internet!</description>
	<lastBuildDate>Thu, 15 Nov 2012 00:36:15 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Setting fonts in Android automatically</title>
		<link>http://sergiandreplace.com/blog/2012/11/15/dealing-with-fonts-and-inflaters-in-android/</link>
		<comments>http://sergiandreplace.com/blog/2012/11/15/dealing-with-fonts-and-inflaters-in-android/#comments</comments>
		<pubDate>Thu, 15 Nov 2012 00:34:37 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[automatize custom fonts]]></category>
		<category><![CDATA[custom fonts]]></category>
		<category><![CDATA[fonts]]></category>
		<category><![CDATA[Inflater]]></category>
		<category><![CDATA[layout]]></category>
		<category><![CDATA[LayoutInflater.Factory]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=348</guid>
		<description><![CDATA[<p>From some time ago we have been dealing with the idea of automating the use of custom fonts in Android apps. By default, you need to manually set the typeface by code view-by-view, as you can&#8217;t define it in the layouts. Pain in the ass.</p> <p>After getting some inspiration from Eric Burke and discussing it [...]]]></description>
				<content:encoded><![CDATA[<p>From some time ago we have been dealing with the idea of automating the use of custom fonts in Android apps. By default, you need to manually set the typeface by code view-by-view, as you can&#8217;t define it in the layouts. Pain in the ass.</p>
<p>After getting some inspiration from Eric Burke and discussing it with my colleague Xavi Rigau, we were thinking on modify the inflate process to automatically set the font on View objects constructions, so I&#8217;ve started to investigate.</p>
<h3>Inflating the inflatable Inflate</h3>
<p>An inflater has the responsibility of translating an XML layout into a tree of instantiated objects. If you look at the LayoutInflater class (<a title="LayoutInflater Javadoc" href="https://developer.android.com/reference/android/view/LayoutInflater.html">LayoutInflater javadoc</a>) you&#8217;ll notice that the way to get an inflater is using the method getLayoutinflater or getSystemService.</p>
<p>In order to modify the behaviour, you must use the method setFactory to provide an object that implements LayoutInflater.Factory interface (<a title="LayoutInflater.Factory Javadoc" href="https://developer.android.com/reference/android/view/LayoutInflater.Factory.html">LayoutInflater.Factory javadoc</a>). This interface has a single method, onCreateView. This method receives the xml tag from the layout, the current context and a set of attributes from the tag. It could return an instantiated object that will be used to represent the tag, or null, in which case the Factory delegates the responsibility of creating the object to the parent inflater.</p>
<p>I&#8217;ve found this incredible article explaining how to use the inflater in order to set a background color menu options: <a title="How to change the text color of Android options menu" href="http://www.gitshah.com/2011/06/how-to-change-text-color-of-android.html">How to change the text color of Android options menu</a></p>
<p>As we may see in the example, it compares the tag name with the class FQN com.android.internal.view.menu.IconMenuItemView, if it matches, then it creates the View manually and uses it as result of the  onCreateView.</p>
<p>Notice that the change is done in a Runnable object set by a a Handler. This is because after being created the object is still manipulated by the inflater, and the color change will be reverted. Using Handler, we ensure the method responsible of the change will be executed once the execution stack of the thread is empty.</p>
<p>As this example was similar to my objective, I&#8217;ve started pulling the thread&#8230;</p>
<h3>These are not the inflaters you are looking for</h3>
<p>My first approach was trying to modify the example in order to instantiate the object whenever the type. But that&#8217;s where I got my first surprise.</p>
<p>If the layout tag says TextView, then you will receive the value TextView as onCreateView parameter, but when invoking the createView method, you need to provide the whole FQN: android.widget.TextView.</p>
<p>So, how to match these names for all cases? my first idea was having a list of paired names saying that &#8220;this&#8221; tag means &#8220;that&#8221; class. But then I decided to check how actually is Android doing it. After a bit of research, I&#8217;ve found that the actual class with this responsability is not in the API, but in the OS source code itself, as it could depend on the device. Here is a link to the right file: <a title="PhoneLayoutInflater.java" href="https://github.com/android/platform_frameworks_policies_base/blob/master/phone/com/android/internal/policy/impl/PhoneLayoutInflater.java">PhoneLayoutInflater.java</a></p>
<p>What? I was expecting something more sofisticated. It just tries some known prefixes for each tags. Keeping in mind that this code could be executed thousands of times in Android,  at least caching the pairs will be nice. Not sure, it looks quite brute force for a method so important.</p>
<p>With all this info, I&#8217;ve created my own Factory. You can download it from a sample project in <a href="http://kcy.me/ce6b">Google Code</a>.</p>
<p>I&#8217;ve added two configuration values via string resources:</p>
<ol>
<li>fontInflaterPackages: a list of comma-separated package names that should be tried to concatenate to tag name apart from the system ones</li>
<li>fontInflaterTypeface: relative path in the assets folder to the font file to load</li>
</ol>
<p>There is still a lot of room for improvement, for example, if something is not correctly setup when implementing this Factory the app will crash in a crazy way instead of giving proper errors. And caching the known tag-FQN matches in a map will be nice.</p>
<h3>Lowering the coupling</h3>
<p>In order to create views, you must invoke the createView method, but this belongs to the LayoutInflater class. In order to avoid excesive coupling, I&#8217;ve implemented a reduced version of the method in the factory.</p>
<p>A better way to do that will be implement the Factory interface in a common base Activity class that implements the interface, so you can freely invoke the getLayoutInflater().createView() method.</p>
<p>As said, I did it separated for the sake of the example, but in real world I&#8217;ll use a BaseActivity class.</p>
<p>If you download and execute the sample app, you&#8217;ll see all widgets in the layout in a nice Comic Sans font (mwahaha!)</p>
<p>I&#8217;ve tested the method with bigger apps and it works nice. Except in one case. Fragments.</p>
<h3>Ehem&#8230; fragments?</h3>
<p>Yes, fragments. This doesn&#8217;t work with fragments when using the ActivityFragment class from Compatibility library. Why?</p>
<p>A LayoutInflater can only have one Factory assigned at a time, and it can only be assigned once. So, if getLayoutInflater().getFactory() is diferent from null, trying to assign a new Factory will throw an exception. There is a method for cloning the LayoutInflater without factory so you can assign yours, but this doesn&#8217;t work in this case.</p>
<p>The class ActivityFragment is quite a weird thing. It is an Activity with extra functionalities, but is not the base class for activities so it implements some things privately that in later versions of Android are supposed to be there.</p>
<p>In this case, ActivityFragment implements the LayoutInflater.Factory interface by itself, and it has its own onCreateView method, as it should treat the tag Fragment in an special way (in fact, if the tag is not fragment, it return null).</p>
<p>So, how to proceed? I think here we should extend the class and override the onCreateView method with our magic tricks, but calling super method when the tag is Fragment.</p>
<h3>Finally&#8230;</h3>
<p>This article is a good example on how to investigate on the source code to find how things work on Android. We as Android developers are lucky to work on a Open Source system that we can strangle to confess how things work.</p>
<p>Keep in mind that I&#8217;m talking about several Android mid-low level topics that I&#8217;ve investigated and learned by myself, so the probability of saying some nonsense or a stupid affirmation is quite high.</p>
<p>This still needs a lot of testing, as there are many cases to test and pitfalls to avoid. For example, I know it won&#8217;t work with viewStubs, as they have their own inflater executed when needed, it just needs more work. Anyways, this is a good start, and of course, any comment or improvement you can propose will be welcomed.</p>
<p>Also, playing with fonts is dangerous. I&#8217;ve tested with comic sans for the joke and because it&#8217;s easy to recognize when it&#8217;s used in comparison with system fonts. But, please, do not use it. It&#8217;s ugly, it&#8217;s inconvenient and it&#8217;s unreadable. Keep Android clean of comic sans. Amen.</p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/11/15/dealing-with-fonts-and-inflaters-in-android/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Introducing RaREST, a brand new Android Rest Client library.</title>
		<link>http://sergiandreplace.com/blog/2012/11/13/introducing-rarest-a-brand-new-android-rest-client-library/</link>
		<comments>http://sergiandreplace.com/blog/2012/11/13/introducing-rarest-a-brand-new-android-rest-client-library/#comments</comments>
		<pubDate>Tue, 13 Nov 2012 00:22:07 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=345</guid>
		<description><![CDATA[<p>I&#8217;ve published a preliminary version of my Rest library RaREST (v.0.9). There are still a couple of things missing (specially logging configuration) and much more testing won&#8217;t hurt anyone, but if any of you wants to try it, feel free to download and give feedback.</p> <p>RaREST is based on a single configuration file that contains [...]]]></description>
				<content:encoded><![CDATA[<p><img class="alignleft" src="http://code.google.com/p/rarest/logo?cct=1350518812" alt="" width="76" height="55" />I&#8217;ve published a preliminary version of my Rest library RaREST (v.0.9). There are still a couple of things missing (specially logging configuration) and much more testing won&#8217;t hurt anyone, but if any of you wants to try it, feel free to download and give feedback.</p>
<p>RaREST is based on a single configuration file that contains all the rest services info needed to invoke them, so it makes the amount of code needed very short.</p>
<p>It supports using services as template for other services, preprocessing and postprocessing of the REST call and many other functionalities.</p>
<p>There is still lack for a lot of improvement (anybody said mulipart?) but is a good starting point.</p>
<p>It&#8217;s licensed under Apache 2.0 and you cand find source, downloadables and documentation on <a href="http://code.google.com/p/rarest/">http://code.google.com/p/rarest/</a></p>
<p>Enjoy it!</p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/11/13/introducing-rarest-a-brand-new-android-rest-client-library/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Uri que te uri</title>
		<link>http://sergiandreplace.com/blog/2012/08/27/uri-que-te-uri/</link>
		<comments>http://sergiandreplace.com/blog/2012/08/27/uri-que-te-uri/#comments</comments>
		<pubDate>Mon, 27 Aug 2012 16:06:57 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Dev]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=336</guid>
		<description><![CDATA[<p>Hola</p> <p>Me estaba peleando con la camara de Android, y tras &#8220;invertir&#8221; todo el dia he descubierto una cosilla que a lo mejor os interesa saber.</p> <p>Estaba llamando a un intent de camara para que me devolviese un fichero, para ello, debemos pasarle un extra con nombre MediaStore.EXTRA_OUTPUT que contenga un objecto Uri apuntando al [...]]]></description>
				<content:encoded><![CDATA[<p>Hola</p>
<p>Me estaba peleando con la camara de Android, y tras &#8220;invertir&#8221; todo el dia he descubierto una cosilla que a lo mejor os interesa saber.</p>
<p>Estaba llamando a un intent de camara para que me devolviese un fichero, para ello, debemos pasarle un extra con nombre MediaStore.EXTRA_OUTPUT que contenga un objecto Uri apuntando al nombre.</p>
<p>Pues bien, hay varias formas de generar un Uri con métodos de clase:</p>
<p>a) Uri.fromFile(File newUri)</p>
<p>b) Uri.parse(String newUri)</p>
<p>Parece que ambos deberian generar el mismo contenido, pero&#8230;. CATACROCKER!</p>
<p>Uri.parse(&#8220;/mnt/sdcard/img/photo.jpg&#8221;) genera un objeto uri descafeinado. Vamos, le rellena el campo Uri.mPath y pa casa.</p>
<p>Uri.fromFile(new File(&#8220;/mnt/sdcard/img/photo.jpg&#8221;)) genera un objeto uri con todas sus propiedades y vitaminas.</p>
<p>Pues si al intent de la cámara le pasas el Uri descafeinado, no funciona, si le pasas el segundo (creado con FIle) funciona perfectamente.</p>
<p>Nada, sólo quería compartirlo.</p>
<p><strong>Update 28-agosto-2012</strong></p>
<p>Como dice <em>kix2902</em> en los comentarios, el Uri.parse funciona con un path del tipo &#8220;file://&#8230;&#8221;.  Lo que no entiendo es por que con una uri incorrecta parsea mal y se queda tan ancho en vez de lanzar una excepción como toca, o al menos no aparece una indicación en la documentación al respecto.</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/08/27/uri-que-te-uri/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Seguimos con Maven. Plantillas.</title>
		<link>http://sergiandreplace.com/blog/2012/07/02/seguimos-con-maven-plantillas/</link>
		<comments>http://sergiandreplace.com/blog/2012/07/02/seguimos-con-maven-plantillas/#comments</comments>
		<pubDate>Mon, 02 Jul 2012 08:48:26 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Dev]]></category>
		<category><![CDATA[Maven]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=323</guid>
		<description><![CDATA[<p>¡Hola!</p> <p>Yo sigo erre que erre con Maven. El siguiente paso ha sido crearme una plantilla que contenga la info común en los proyectos Android. Esto es, por supuesto, aplicable a cualquier tipo de proyecto. Los pasos son:</p> <p>Crear un proyecto nuevo para el POM</p> <p>En Eclipse creamos un proyecto nuevo de tipo Maven, Maven [...]]]></description>
				<content:encoded><![CDATA[<p>¡Hola!</p>
<p>Yo sigo erre que erre con Maven. El siguiente paso ha sido crearme una plantilla que contenga la info común en los proyectos Android. Esto es, por supuesto, aplicable a cualquier tipo de proyecto. Los pasos son:</p>
<p><strong>Crear un proyecto nuevo para el POM</strong></p>
<p>En Eclipse creamos un proyecto nuevo de tipo Maven, Maven Project y hacemos clic en siguiente.</p>
<p>Seleccionamos <strong>Create a simple project (skip archetype selection)</strong> y next.</p>
<p>Introducimos la información del pom. En este caso hablamos de como nos referiremos a nuestra plantilla. Por ejemplo:</p>
<ul>
<li>GroupId: com.sergiandreplace.template</li>
<li>ArtifactId: android</li>
<li>Version: 0.0.1-SNAPSHOT</li>
<li>Packaging: pom &lt;&#8211; Aquí está la clave del asunto!!!</li>
<li>Name: Android POM template</li>
</ul>
<p>Por último hacemos clic en Finish y nos creará el proyecto.</p>
<p><strong>Crear el POM base</strong></p>
<p><strong></strong>En este caso, el pom es parecido al que creamos en el último post sobre maven, pero con algunos cambios.</p>
<pre>&lt;project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
  &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  &lt;groupId&gt;com.sergiandreplace.template&lt;/groupId&gt;
  &lt;artifactId&gt;android&lt;/artifactId&gt;
  &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
  &lt;packaging&gt;apk&lt;/packaging&gt;
  &lt;name&gt;android&lt;/name&gt;
  &lt;properties&gt; 
        &lt;android.version&gt;2.1.2&lt;/android.version&gt; 
        &lt;android.apkName&gt;compiled&lt;/android.apkName&gt; 
        &lt;android.api&gt;7&lt;/android.api&gt; 
  &lt;/properties&gt;
  &lt;dependencies&gt;
        &lt;dependency&gt;
            &lt;groupId&gt;com.google.android&lt;/groupId&gt;
            &lt;artifactId&gt;android&lt;/artifactId&gt;
            &lt;version&gt;${android.version}&lt;/version&gt;
            &lt;scope&gt;provided&lt;/scope&gt;
        &lt;/dependency&gt;
  &lt;/dependencies&gt;
  &lt;build&gt;
        &lt;finalName&gt;${android.apkName}&lt;/finalName&gt;
        &lt;sourceDirectory&gt;src&lt;/sourceDirectory&gt;
        &lt;pluginManagement&gt;
            &lt;plugins&gt;
                &lt;plugin&gt;
                    &lt;groupId&gt;com.jayway.maven.plugins.android.generation2&lt;/groupId&gt;
                    &lt;artifactId&gt;android-maven-plugin&lt;/artifactId&gt;
                    &lt;version&gt;3.1.1&lt;/version&gt;
                    &lt;extensions&gt;true&lt;/extensions&gt;
                &lt;/plugin&gt;
                &lt;!--This plugin's configuration is used to store Eclipse m2e settings 
                    only. It has no influence on the Maven build itself. --&gt;
                &lt;plugin&gt;
                    &lt;groupId&gt;org.eclipse.m2e&lt;/groupId&gt;
                    &lt;artifactId&gt;lifecycle-mapping&lt;/artifactId&gt;
                    &lt;version&gt;1.0.0&lt;/version&gt;
                    &lt;configuration&gt;
                        &lt;lifecycleMappingMetadata&gt;
                            &lt;pluginExecutions&gt;
                                &lt;pluginExecution&gt;
                                    &lt;pluginExecutionFilter&gt;
                                        &lt;groupId&gt;
                                            com.jayway.maven.plugins.android.generation2
                                        &lt;/groupId&gt;
                                        &lt;artifactId&gt;
                                            android-maven-plugin
                                        &lt;/artifactId&gt;
                                        &lt;versionRange&gt;
                                            [3.1.1,)
                                        &lt;/versionRange&gt;
                                        &lt;goals&gt;
                                            &lt;goal&gt;proguard&lt;/goal&gt;
                                        &lt;/goals&gt;
                                    &lt;/pluginExecutionFilter&gt;
                                    &lt;action&gt;
                                        &lt;ignore&gt;&lt;/ignore&gt;
                                    &lt;/action&gt;
                                &lt;/pluginExecution&gt;
                            &lt;/pluginExecutions&gt;
                        &lt;/lifecycleMappingMetadata&gt;
                    &lt;/configuration&gt;
                &lt;/plugin&gt;
            &lt;/plugins&gt;
        &lt;/pluginManagement&gt;
        &lt;plugins&gt;
            &lt;plugin&gt;
                &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
                &lt;artifactId&gt;maven-compiler-plugin&lt;/artifactId&gt;
                &lt;version&gt;2.3.2&lt;/version&gt;
                &lt;configuration&gt;
                    &lt;source&gt;${android.version}&lt;/source&gt;
                    &lt;target&gt;${android.version}&lt;/target&gt;
                &lt;/configuration&gt;
            &lt;/plugin&gt;
            &lt;plugin&gt;
                &lt;groupId&gt;com.jayway.maven.plugins.android.generation2&lt;/groupId&gt;
                &lt;artifactId&gt;android-maven-plugin&lt;/artifactId&gt;
                &lt;configuration&gt;
                    &lt;sdk&gt;
                        &lt;path&gt;${env.ANDROID_HOME}&lt;/path&gt;
                        &lt;platform&gt;${android.api}&lt;/platform&gt;
                    &lt;/sdk&gt;
                &lt;/configuration&gt;
                &lt;extensions&gt;true&lt;/extensions&gt;
            &lt;/plugin&gt;
        &lt;/plugins&gt;
    &lt;/build&gt;
&lt;/project&gt;</pre>
<p>Y con esto tendriamos la plantilla. Básicamente, he extraido los valores que cambian de proyecto en proyecto a variables, y además he creado una sección con valores por defecto.</p>
<p>Para publicarlo en nuestro repo local, tan sólo debemos ejecutar un mvn install y el sólo nos lo añadirá.</p>
<p>Ya tenemos la plantilla lista.</p>
<p><strong>Heredar la plantilla</strong></p>
<p>Ahora en nuestro proyecto Android con maven (recordad el mavenize project) tan sólo necesitamos tener el siguiente pom:</p>
<pre>&lt;project xmlns="http://maven.apache.org/POM/4.0.0" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
  &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  &lt;groupId&gt;com.sergiandreplace&lt;/groupId&gt;
  &lt;artifactId&gt;MyApplication&lt;/artifactId&gt;
  &lt;version&gt;1.0.0-SNAPSHOT&lt;/version&gt;
  &lt;packaging&gt;apk&lt;/packaging&gt;
  &lt;name&gt;android&lt;/name&gt;
  &lt;parent&gt; 
        &lt;artifactId&gt;android&lt;/artifactId&gt; 
        &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt; 
        &lt;groupId&gt;com.sergiandreplace.project&lt;/groupId&gt; 
  &lt;/parent&gt;
  &lt;properties&gt;
        &lt;android.version&gt;2.1.2&lt;/android.version&gt; 
        &lt;android.apkName&gt;myapp&lt;/android.apkName&gt; 
        &lt;android.api&gt;7&lt;/android.api&gt;
  &lt;/properties&gt;
&lt;/project&gt;</pre>
<p>Como veis, aquí le indico, por un lado, de que proyecto hereda la configuración, y por otro lado que valores debe utilizar para las variables. Si  mirais el POM efectivo, vereis que contiene toda la configuración correctamente establecida.</p>
<p><strong>Consideraciones finales</strong></p>
<p>Recordad que si trabajais en equipo, es necesario que todo el mundo tenga las mismas plantillas o la podeis liar muy parda. En ese caso, os recomiendo tener algún repositorio de Maven (p.ej.: Nexus) y tener las plantillas publicadas en el servidor.</p>
<p>El uso de plantillas hace más sencillo el aplicar nuevas configuraciones y opciones a los proyectos existentes, y nos permite configurar los proyectos nuevos de forma más rápida.</p>
<p>Ale, gozadlo.</p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/07/02/seguimos-con-maven-plantillas/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ejemplos y comentarios del Barcelona Startup Weekend Bootcamp</title>
		<link>http://sergiandreplace.com/blog/2012/06/27/ejemplos-y-comentarios-del-barcelona-startup-weekend-bootcamp/</link>
		<comments>http://sergiandreplace.com/blog/2012/06/27/ejemplos-y-comentarios-del-barcelona-startup-weekend-bootcamp/#comments</comments>
		<pubDate>Wed, 27 Jun 2012 18:03:57 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[CatDroid]]></category>
		<category><![CDATA[Charlas]]></category>
		<category><![CDATA[Dev]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=320</guid>
		<description><![CDATA[<p>El pasado sábado tuve la suerte de poder impartir el Bootcamp del Barcelona Startup Wekeend. Durante esta sesión, vimos una introducción al servicio de GAE para montar un servidor rest y como utilizar la libreria AndroidAnnotations para hacer aplicaciones Android de forma rápida.</p> <p>Por razones que no acababa de entender, no conseguimos hacer funcionar la [...]]]></description>
				<content:encoded><![CDATA[<p><!--:es-->El pasado sábado tuve la suerte de poder impartir el Bootcamp del Barcelona Startup Wekeend. Durante esta sesión, vimos una introducción al servicio de GAE para montar un servidor rest y como utilizar la libreria AndroidAnnotations para hacer aplicaciones Android de forma rápida.</p>
<p>Por razones que no acababa de entender, no conseguimos hacer funcionar la libreria AndroidAnnotations como cliente rest, y como sospechaba que era un tema de librerias, prometí mirarlo con calma y postear un proyecto que funcionase.</p>
<p>Después de mucho investigar he encontrado la causa de los problemas y he podido solucionarlos.<!--:--><span id="more-320"></span><!--:es--></p>
<p>Relato un poco de donde se originaron.</p>
<p><strong>Spring for Android</strong></p>
<p>La librería Spring for Android alcanzó su &#8220;mayoría de edad&#8221; recientemente, publicando la versión 1.0.</p>
<p>¿A que uno espera que no haya grandes cambios entre una RC1 y la versión final? pues resulta que sí, que esta versión incluye un gran cambio, y es que, por motivos de rendimiento, ya no se incluye ningún MessageConverter predeterminado. Los MessageConverter son los encargados de traducir el formato recibido y deserializarlo.</p>
<p>Cito de <a href="https://github.com/excilys/androidannotations/wiki/Rest%20API">https://github.com/excilys/androidannotations/wiki/Rest%20API</a>:</p>
<p>Prior to the Spring Android 1.0 release, some <code>MessageConverter</code>s were included by default when creating a new <code>RestTemplate</code> instance. It is not the case any more, for performance reasons. This means that you need to add those manually.</p>
<p>Y más info en <a href="https://github.com/excilys/androidannotations/issues/206">https://github.com/excilys/androidannotations/issues/206</a></p>
<p>Mientras los chicos de AndroidAnnotations lo arreglan, mi consejo es volver a la Spring for Android RC1.</p>
<p><strong>Jackson</strong></p>
<p>Y por si fuera poco, los amigos de Jackson suben de la 1.9.x a la versión 2. Y después de algunos cabezazos contra la pared leo esto (http://stackoverflow.com/a/10114164):</p>
<p>The problem is that Spring doesn&#8217;t work with Jackson 2.0</p>
<p>Vamos, peor imposible.</p>
<p><strong>El código</strong></p>
<p><strong></strong>Como tanto cambio reciente nos pilla a todos un poco a traspiés, el código de ejemplo que he puesto utiliza Spring for Android RC1 y Jackson 1.9.7 que son las versiones que funcionan bien.</p>
<p>Para casos como estos es para los que va bien Maven, ya que os hubiese pasado las dependencias de otro proyecto, y hubiese funcionado a la primera.</p>
<p>Que le vamos a hacer, meses trabajando con unas librerias, y el día que las vuelves a descargar, ha cambiado todo. Ya es verdad que uno nunca va lo suficientemente preparado.</p>
<p>Ah! que no se me olvide, también he subido el código a un repositorio de Google Code, lo podréis encontrar en <a href="http://code.google.com/p/bsw-catdroid-bootcamp-2012/">http://code.google.com/p/bsw-catdroid-bootcamp-2012/</a>. Este simplemente implementa una llamada GET y muestra un Toast por registro. Os dejo como ejercicio hacer el PUT. Cualquier duda, este mismo post puede servirnos de discusión.</p>
<p>Saludos<!--:--></p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/06/27/ejemplos-y-comentarios-del-barcelona-startup-weekend-bootcamp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Usar Maven con Android</title>
		<link>http://sergiandreplace.com/blog/2012/06/27/usar-maven-con-android/</link>
		<comments>http://sergiandreplace.com/blog/2012/06/27/usar-maven-con-android/#comments</comments>
		<pubDate>Wed, 27 Jun 2012 12:15:06 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Dev]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=294</guid>
		<description><![CDATA[<!--:es-->La idea de este artículo es presentar los pasos necesarios para configurar Eclipse para utilizarlo con Maven en proyectos Android obteniendo la mínima configuración.
<!--:-->]]></description>
				<content:encoded><![CDATA[<p><!--:es-->La idea de este artículo es presentar los pasos necesarios para configurar Eclipse para utilizarlo con Maven en proyectos Android. Estos pasos son:</p>
<p><strong>Descargar herramientas</strong></p>
<p>Descargamos Eclipse si no lo tuviesemos (en mi caso utilizo Eclipse Classic 3.7.2) desde <a href="http://www.eclipse.org/downloads/">http://www.eclipse.org/downloads/</a>.</p>
<p>Configuramos el sdk de Android i el ADT (http://android.com)</p>
<p>Descargamos Maven desde <a href="http://maven.apache.org/download.html">http://maven.apache.org/download.html</a> (para el ejemplo usamos 3.0.4)</p>
<p>Asumimos que instalamos las herramientas en D:\eclipse, D:\android-sdk-windows y en D:\maven si tu ruta es diferente, cambialo donde toque.</p>
<p><strong>Instalar plugin de Eclipse para Maven (m2Eclipse)</strong></p>
<p>Desde <a href="http://www.eclipse.org/m2e/download/">http://www.eclipse.org/m2e/download/</a> podemos ver las diferentes rutas de descarga.</p>
<p>En nuestro caso, en Eclipse, vamos a Help, Install New Software&#8230; e introducimos http://download.eclipse.org/technology/m2e/releases como url.</p>
<p><strong>Configurar el plugin de Maven</strong></p>
<p>En mi caso configuro siempre lo siguiente:</p>
<p>En la venta de preferencias (Window, Preferences) seleccionamos Maven\Installations. Allí podemos añadir el ejecutable de Maven. Así nos aseguramos que el plugin y la linea de comandos utilizan la misma versión.</p>
<p><strong>Instalar el conector de Android para Maven</strong></p>
<p>Ahora hay que decirle al plugin que &#8220;entienda&#8221; los proyectos de Android. Para eso tenemos que instalar el conector de Android. Dentro de la pantalla de preferencias, en Maven\Discovery, hacemos clic en Open Catalog. Se nos abrirá el listado de conectores.</p>
<p>Buscamos &#8216;Maven Integration for Android Development Tools&#8217; (escribe Android y acabarás antes) y lo instalamos.</p>
<p>Ya estamos listos para trabajar con Maven para Android.</p>
<p><strong>Configurar un proyecto para usar Maven</strong></p>
<p>Nunca he conseguido que creando un proyecto nuevo de Maven directamente funcione. Lo que hago es crear un proyecto normal, y luego, podemos hacer clic con el botón derecho sobre la raiz del proyecto, y seleccionar Configure, Convert to Maven Project.</p>
<p>Así se nos transformará en un proyecto de Maven, pero nos toca configurar el POM. Básicamente, utilizo la siguiente plantilla:</p>
<pre> 
&lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
  &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  &lt;groupId&gt;com.tempos21&lt;/groupId&gt;
  &lt;artifactId&gt;MavenTest&lt;/artifactId&gt;
  &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
  &lt;packaging&gt;apk&lt;/packaging&gt;
  &lt;name&gt;android&lt;/name&gt;
  &lt;dependencies&gt;
          &lt;dependency&gt;
            &lt;groupId&gt;com.google.android&lt;/groupId&gt;
            &lt;artifactId&gt;android&lt;/artifactId&gt;
            &lt;version&gt;2.1.2&lt;/version&gt;
            &lt;scope&gt;provided&lt;/scope&gt;
          &lt;/dependency&gt;
  &lt;/dependencies&gt;
  &lt;build&gt;
        &lt;finalName&gt;MavenTest&lt;/finalName&gt;
        &lt;sourceDirectory&gt;src&lt;/sourceDirectory&gt;
        &lt;pluginManagement&gt;
            &lt;plugins&gt;
                &lt;plugin&gt;
                    &lt;groupId&gt;com.jayway.maven.plugins.android.generation2&lt;/groupId&gt;
                    &lt;artifactId&gt;android-maven-plugin&lt;/artifactId&gt;
                    &lt;version&gt;3.1.1&lt;/version&gt;
                    &lt;extensions&gt;true&lt;/extensions&gt;
                &lt;/plugin&gt;
                &lt;!--This plugin's configuration is used to store Eclipse m2e settings 
                    only. It has no influence on the Maven build itself. --&gt;
                &lt;plugin&gt;
                    &lt;groupId&gt;org.eclipse.m2e&lt;/groupId&gt;
                    &lt;artifactId&gt;lifecycle-mapping&lt;/artifactId&gt;
                    &lt;version&gt;1.0.0&lt;/version&gt;
                    &lt;configuration&gt;
                        &lt;lifecycleMappingMetadata&gt;
                            &lt;pluginExecutions&gt;
                                &lt;pluginExecution&gt;
                                    &lt;pluginExecutionFilter&gt;
                                        &lt;groupId&gt;
                                            com.jayway.maven.plugins.android.generation2
                                        &lt;/groupId&gt;
                                        &lt;artifactId&gt;
                                            android-maven-plugin
                                        &lt;/artifactId&gt;
                                        &lt;versionRange&gt;
                                            [3.1.1,)
                                        &lt;/versionRange&gt;
                                        &lt;goals&gt;
                                            &lt;goal&gt;proguard&lt;/goal&gt;
                                        &lt;/goals&gt;
                                    &lt;/pluginExecutionFilter&gt;
                                    &lt;action&gt;
                                        &lt;ignore&gt;&lt;/ignore&gt;
                                    &lt;/action&gt;
                                &lt;/pluginExecution&gt;
                            &lt;/pluginExecutions&gt;
                        &lt;/lifecycleMappingMetadata&gt;
                    &lt;/configuration&gt;
                &lt;/plugin&gt;
            &lt;/plugins&gt;
        &lt;/pluginManagement&gt;
        &lt;plugins&gt;
            &lt;plugin&gt;
                &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
                &lt;artifactId&gt;maven-compiler-plugin&lt;/artifactId&gt;
                &lt;version&gt;2.3.2&lt;/version&gt;
                &lt;configuration&gt;
                    &lt;source&gt;1.6&lt;/source&gt;
                    &lt;target&gt;1.6&lt;/target&gt;
                &lt;/configuration&gt;
            &lt;/plugin&gt;
            &lt;plugin&gt;
                &lt;groupId&gt;com.jayway.maven.plugins.android.generation2&lt;/groupId&gt;
                &lt;artifactId&gt;android-maven-plugin&lt;/artifactId&gt;
                &lt;configuration&gt;
                    &lt;sdk&gt;
                        &lt;path&gt;${env.ANDROID_HOME}&lt;/path&gt;
                        &lt;platform&gt;7&lt;/platform&gt;
                    &lt;/sdk&gt;
                &lt;/configuration&gt;
                &lt;extensions&gt;true&lt;/extensions&gt;
            &lt;/plugin&gt;
        &lt;/plugins&gt;
    &lt;/build&gt;

&lt;/project&gt;</pre>
<p>Y aquí algunos de los valores a configurar:</p>
<ul>
<li>GROUP_ID_DEL_PROYECTO: la ruta canónica del paquete (p.ej.: com.sergiandreplace)</li>
<li>NOMBRE_DEL_PROYECTO: el identificador del paquete que completa la ruta canónica.</li>
<li>VERSION_DE_ANDROID: la versión de Android que utilizamos en la app. Ojo que no valen todas, sólo aquellas que estén en el repositorio. Podemos consultar la lista aquí: <a href="http://mvnrepository.com/artifact/com.google.android/android">http://mvnrepository.com/artifact/com.google.android/android</a></li>
<li>NOMBRE_FINAL_APK: pues eso, el nombre que tendrá el fichero final cuando compilemos.</li>
<li>VERSION_DE_API: versión de api utilizada para compilar en formato numérico. P.ej: 7 para 2.1</li>
</ul>
<p>Si ahora ejecutamos desde la linea de comandos en la carpeta del proyecto</p>
<pre>mvn install</pre>
<p>Se nos instalaran las dependencias necesarias<br />
Ahora si ejecutamos</p>
<pre>mvn android:deploy</pre>
<p>Se nos compilará e instalará en los moviles disponibles desde adt.</p>
<p>También podemos hacer un compilado/ejecución de toda la vida en Eclipse.</p>
<p>Quedan cosas por configurar (donde hacer deploy, certificados, etc) pero esto ya depende de cada proyecto, aquí sólo he mostrado lo mínimo para empezar.<!--:--><!--:en--></p>
<p><!--:--></p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/06/27/usar-maven-con-android/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Jugando con Unity</title>
		<link>http://sergiandreplace.com/blog/2012/04/22/jugando-con-unity/</link>
		<comments>http://sergiandreplace.com/blog/2012/04/22/jugando-con-unity/#comments</comments>
		<pubDate>Sun, 22 Apr 2012 00:50:21 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=285</guid>
		<description><![CDATA[<p>Llevo unos dias jugueteando con Unity (no, el infecto escritorio de Ubuntu no, me refiero a la herramienta de creación de aplicaciones 3d).</p> <p>La verdad, es indecentemente fácil hacer cosas con ella. Subo un ejemplillo para que veais que se hace en un par de horitas con algo de scripting.</p> <p></p> <p></p>]]></description>
				<content:encoded><![CDATA[<p><!--:es-->Llevo unos dias jugueteando con Unity (no, el infecto escritorio de Ubuntu no, me refiero a la herramienta de creación de aplicaciones 3d).</p>
<p>La verdad, es indecentemente fácil hacer cosas con ella. Subo un ejemplillo para que veais que se hace en un par de horitas con algo de scripting.</p>
<p><!--:--><span id="more-285"></span><!--:es--></p>
<p><iframe src="/wp-content/uploads/mine/WebPlayer.html" width="970" height="700"></iframe><!--:--></p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/04/22/jugando-con-unity/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Appunta: demo disponible!</title>
		<link>http://sergiandreplace.com/blog/2012/01/19/appunta-demo-disponible/</link>
		<comments>http://sergiandreplace.com/blog/2012/01/19/appunta-demo-disponible/#comments</comments>
		<pubDate>Thu, 19 Jan 2012 00:23:17 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=282</guid>
		<description><![CDATA[<p>Hola</p> <p>He subido una demo de funcionalidades de Appunta al Market.</p> <p>Podéis encontrarla en <a href="http://kcy.me/6nc1">el Market de Android</a></p> <p>Si alguien se la baja y me comenta si funciona o no funciona, si da problemas o no va bien, lo agradecería enormemente (cervezas gratis para el mejor bughunter!!!)</p> <p>También he subido el código al repositorio [...]]]></description>
				<content:encoded><![CDATA[<p><!--:es-->Hola</p>
<p>He subido una demo de funcionalidades de Appunta al Market.</p>
<p>Podéis encontrarla en <a href="http://kcy.me/6nc1">el Market de Android</a></p>
<p>Si alguien se la baja y me comenta si funciona o no funciona, si da problemas o no va bien, lo agradecería enormemente (cervezas gratis para el mejor bughunter!!!)</p>
<p>También he subido el código al repositorio por si queréis ojearlo. Ah! y he comprado el dominio appunta.com. Algún dia pondré cosas en el, de momento hay un bonito wordpress dedicado al LoremIpsumismo, pero necesito dormir más de 5 horas por lo menos un día.</p>
<p>Ah, y si tenéis ideas para crear nuevos sistemas de visualización de geodatos, pues estaré encantado de oirlas, que ahora toca engordar la librería con widgets. Así a bote pronto se me ocurre, por ejemplo, un visor de rutas de senderismo donde el azimuth no señale al norte geográfico, si no al último punto de la ruta, así vemos el camino &#8220;delante nuestro&#8221;. Igual luego implementado es una castaña muy gordo. Igual no.</p>
<p>¿Y algún conejillo de indias con ganas de implementar en su app una librería que cambia casi cada día? ¿Algún amante del riesgo?</p>
<p>Gracias y buenas noches</p>
<p>P.D.: mañana toca catbeer, así que a los androideros tímidos os invito a venir a conocer a la gente de Catdroid, son todos muy majos, bueno, bastante majos, bueno, casi todos <img src='http://sergiandreplace.com/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> </p>
<p>P.P.D: el icono/logotipo es horrendo, lo se, pero de momento no he podido hacer más, está en la lista de cosas &#8220;que son importantes, pero no urgentes y no tengo ni idea de cuando las haré&#8221;. Se aceptan ayudas y los autores mantienen la autoría, of course <img src='http://sergiandreplace.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>&nbsp;<!--:--></p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/01/19/appunta-demo-disponible/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Appunta saca la otra patita, y oiga, es una pata muy gorda</title>
		<link>http://sergiandreplace.com/blog/2012/01/17/appunta-saca-la-otra-patit/</link>
		<comments>http://sergiandreplace.com/blog/2012/01/17/appunta-saca-la-otra-patit/#comments</comments>
		<pubDate>Tue, 17 Jan 2012 00:11:24 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[Appunta]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=267</guid>
		<description><![CDATA[<p>Hola!</p> <p>Segundo dia del cuaderno de bitácora de Appunta. Y francamente, estoy pletórico. He conseguido armar algo muy potente con una arquitectura muy, muy sencilla (todavía no he llegado a la docena de clases), y por una vez me quedo lejos de la sobreingeniería.</p> <p>¡¡¡Y tengo una captura de pantalla!!!</p> <p><a href="http://postimage.org/image/ekh2uz7zb" target="_blank"></a></p> <p>En las [...]]]></description>
				<content:encoded><![CDATA[<p><!--:es-->Hola!</p>
<p>Segundo dia del cuaderno de bitácora de Appunta. Y francamente, estoy pletórico. He conseguido armar algo muy potente con una arquitectura muy, muy sencilla (todavía no he llegado a la docena de clases), y por una vez me quedo lejos de la sobreingeniería.</p>
<p>¡¡¡Y tengo una captura de pantalla!!!</p>
<p><a href="http://postimage.org/image/ekh2uz7zb" target="_blank"><img class="alignright" style="border-image: initial; border-width: 5px; border-color: white; border-style: solid;" title="Radar!!!" src="http://s15.postimage.org/qz3uvazhn/device_2012_01_17_005306.png" alt="" width="240" height="400" /></a></p>
<p>En las últimas 48h he implementado un montón de cosas:</p>
<ul>
<li>Generada la clase abstracta AppuntaView. Esta se encarga de dibujar la vista utilizando tres métodos. Esta es la explicación extraida del Javadoc</li>
</ul>
<blockquote><p>This is the base class in order to create Views using the Appunta system. The class has all needed calculations and values to retrieve info from points.</p>
<p>It&#8217;s important to understand how this will work. All the stuff happens in the onDraw Method.</p>
<p>The <code><a href="eclipse-javadoc:%E2%98%82=Appunta/src%3Ccom.sergiandreplace.appunta.ui%7BAppuntaView.java%E2%98%83AppuntaView%E2%98%82%E2%98%82onDraw">onDraw</a></code> method has three phases: <strong>preRender</strong>, <strong>pointRendering</strong> &amp; <strong>postRender</strong>.</p>
<ul>
<li>The <strong>preRender</strong> phase triggers the method <code><a href="eclipse-javadoc:%E2%98%82=Appunta/src%3Ccom.sergiandreplace.appunta.ui%7BAppuntaView.java%E2%98%83AppuntaView%E2%98%82%E2%98%82preRender">preRender</a></code>, used to draw all needed elements used in the background.</li>
<li>In the <strong>pointRendering</strong> phase, the method <code><a href="eclipse-javadoc:%E2%98%82=Appunta/src%3Ccom.sergiandreplace.appunta.ui%7BAppuntaView.java%E2%98%83AppuntaView%E2%98%82%E2%98%82calculatePointCoordinates%E2%98%82Point">calculatePointCoordinates(Point)</a></code> is invoked per each on of the points, in order to calculate the screen coordinates for each one of them. Then, they are painted by calling their PaintRenderer.</li>
<li>In the <strong>Post render</strong> phase, the <code><a href="eclipse-javadoc:%E2%98%82=Appunta/src%3Ccom.sergiandreplace.appunta.ui%7BAppuntaView.java%E2%98%83AppuntaView%E2%98%82%E2%98%82postRender%E2%98%82Canvas">postRender(Canvas)</a></code> method is invoked in order to paint the latest layer</li>
</ul>
</blockquote>
<ul>
<li>Este sistema permite implementar nuevas formas de mostrar &#8220;geodatos&#8221; de forma rápida y sencilla. Pintamos un fondo, decidimos las coordenadas de cada punto dentro del canvas, y barnizamos. Y arreando.</li>
<li>A partir de esta implementación, RadarView es como 10 veces más pequeño.</li>
<li>Implementada nueva view (también hereda de AppuntaView) que muestra un panorama donde la distancia se coloca con la altura. Esto con una cámara detras a toda pantalla es una AR de las de diploma.</li>
<li>Con el objetivo de montarlo bien, he creado una clase que hereda de SurfaceView para mostrar la cámara.</li>
<li>Tengo que mirar la diferencia entre View y SurfaceView, que me da en la nariz que la segunda me va a venir bien para estas cosas.</li>
<li>También he documentado más</li>
<li>¡Y he subido un bonito sample! muestra algunas ciudades alrededor de Barcelona. Ojo que el punto central no se mueve y constantemente cree que estás en Barcelona. Los LocationServices para otro día. El sample está aquí: <a href="http://code.google.com/p/appunta/downloads/detail?name=appunta-sample-20120117.apk">http://code.google.com/p/appunta/downloads/detail?name=appunta-sample-20120117.apk</a></li>
</ul>
<p>De momento eso es todo (que no es poco). Ahora toca hacer un poco de limpieza y documentación, pero en general estoy muy satisfecho con el trabajo conseguido.</p>
<p>Supongo que huelga decir lo de que se agradecen comentarios, vivas, bravos, bughunters,  donaciones, cheques sopresa, corticoles y cualquier aportación que se desee dar al autor.<!--:--></p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/01/17/appunta-saca-la-otra-patit/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Appunta &#8211; un motor de AR</title>
		<link>http://sergiandreplace.com/blog/2012/01/16/appunta-un-motor-de-ar/</link>
		<comments>http://sergiandreplace.com/blog/2012/01/16/appunta-un-motor-de-ar/#comments</comments>
		<pubDate>Mon, 16 Jan 2012 09:54:28 +0000</pubDate>
		<dc:creator>sergi</dc:creator>
				<category><![CDATA[Android]]></category>

		<guid isPermaLink="false">http://sergiandreplace.com/?p=263</guid>
		<description><![CDATA[<p>Hola</p> <p>Estoy haciendo un motor de Realidad Aumentada GeoLocalizada. Tengo el proyecto al 40%, pero ya se puede enseñar.</p> <p>Al contrario de otros como Mixare que funcionan como una caja negra, este funciona con un conjunto de pequeños componentes que se comunican entre ellos, permitiendo un alto nivel de personalización, aunque funciona out-of-the-box</p> <p>De momento [...]]]></description>
				<content:encoded><![CDATA[<p><!--:es-->Hola</p>
<p>Estoy haciendo un motor de Realidad Aumentada GeoLocalizada. Tengo el proyecto al 40%, pero ya se puede enseñar.</p>
<p>Al contrario de otros como Mixare que funcionan como una caja negra, este funciona con un conjunto de pequeños componentes que se comunican entre ellos, permitiendo un alto nivel de personalización, aunque funciona out-of-the-box</p>
<p>De momento el único componente publicado es un View que permite mostrar puntos en una brújula.</p>
<p>El código es OS con licencia Apache 2.0. Así que, comparte y disfruta, pero menciona y agradece.</p>
<p>Encontrareis el proyecto en <a title="http://code.google.com/p/appunta/" href="http://code.google.com/p/appunta/">http://code.google.com/p/appunta/</a></p>
<p>Espero tener el módulo de AR &#8220;enseñable&#8221; en los próximos días. Os mantendré informados.</p>
<p>En el apartado de wiki hay algo de documentación, no mucha, pero habrá más en los próximos días.</p>
<p>Si os bajáis el source, es una app de prueba que muestra el radar con 4 puntos (Madrid, Zaragoza, Toulousse y París). El centro está fijo en BCN, así que estés donde estés ves los mismos puntos. El módulo de posicionamiento está a medias y no lo he publicado. Ojo, que la parte de la activity es sólo para pruebas, con lo que la calidad del código de esa parte deja mucho que desear, ya que es mi pequeño campo de pruebas.</p>
<p>Se aceptan sugerencias, bug-hunting, bug-fixing, groupies y jamones a la dirección de siempre.</p>
<p>Saludos!</p>
<p>&nbsp;<!--:--></p>
]]></content:encoded>
			<wfw:commentRss>http://sergiandreplace.com/blog/2012/01/16/appunta-un-motor-de-ar/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
