android-developers
[Arriba] [Todas las Listas]

Re: [android-developers] Re: La Memoria no es reclaimed bastante rápido

To: android-developers@xxxxxxxxxxxxxxxx
Subject: Re: [android-developers] Re: La Memoria no es reclaimed bastante rápido cuándo la Actividad es cerrada
From: Kristopher Micinski <krismicinski@xxxxxxxxx>
Date: Mon, 31 Oct 2011 19:17:59 -0400
Delivery-date: Mon, 31 Oct 2011 19:18:31 -0400
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=beta; h=x-beenthere:received-spf:mime-version:in-reply-to:references:date :message-id:subject:from:to:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:x-google-group-id:list-post:list-help:list-archive:sender :list-subscribe:list-unsubscribe:content-type :content-transfer-encoding; bh=9mligQOHv8FevLo7Ja/9hA6peqFelZCNw0KAsBwNVAs=; b=S61id/04d5NwzHLAmXW0wq38LatYZri1skJaEgKEsHAsaKM9LUog5d3YlfhJDqqZ9C saAoNJCQflIvHScMPzg48Uxhvj/kDX0zQStHdYVWxZaYYAL7q/S3DCsiTulxnkq3AMjz Iz57gG6vqBo/Nhmt58RrHCnVKKAJbAt4P3Q00=
Envelope-to: traductor@xxxxxxxxxxx
In-reply-to: <32d693a9-d2b6-4652-936c-bab4dd0c5309@v5g2000vbh.googlegroups.com>
List-archive: <http://groups.google.com/group/android-developers?hl=en_US>
List-help: <http://groups.google.com/support/?hl=en_US>, <mailto:android-developers+help@googlegroups.com>
List-id: <android-developers.googlegroups.com>
List-post: <http://groups.google.com/group/android-developers/post?hl=en_US>, <mailto:android-developers@googlegroups.com>
List-subscribe: <http://groups.google.com/group/android-developers/subscribe?hl=en_US>, <mailto:android-developers+subscribe@googlegroups.com>
List-unsubscribe: <http://groups.google.com/group/android-developers/subscribe?hl=en_US>, <mailto:android-developers+unsubscribe@googlegroups.com>
Mailing-list: list android-developers@xxxxxxxxxxxxxxxx; contact android-developers+owners@xxxxxxxxxxxxxxxx
References: <d929d42b-b18c-47df-b99c-fe6865f5092c@eh5g2000vbb.googlegroups.com> <CALLdnhPfKLEeg_za7pmtXvqkRxZo75GLAGoN+mKKqcj_gKa3uA@mail.gmail.com> <32197a97-f08b-4f5e-8f40-90a50062e1bf@x20g2000vbl.googlegroups.com> <CALLdnhPx9z+AWqvO9VZQADLgg_mx3vLh1VgfP3iyoER7nuRr7A@mail.gmail.com> <32d693a9-d2b6-4652-936c-bab4dd0c5309@v5g2000vbh.googlegroups.com>
Reply-to: android-developers@xxxxxxxxxxxxxxxx
Sender: android-developers@xxxxxxxxxxxxxxxx
Incluso entonces, esto no es realmente un *Android cuestión específica.  Es más
de un *Java cuestión específica, o una ingeniería de software cuestión
relacionada.  Aun así, podría ser guapo de incluir un poco de información
sobre colección de basura y memoria *reclaiming cuando relaciona a *Android.


*kris

En *Mon, *Oct 31, 2011 en 5:00 PM, *Efi *Merdler-*Kravitz
<efi.merdler@xxxxxxxxx> escribió:
> *Thanks. Laborable. Cualquier posibilidad de añadir un capítulo en administración de memoria en
> vuestro *online libro - "Sintonía *Android Aplicaciones" ?
>
>
>
> En *Oct 31, 10:17 *pm, Mark *Murphy <mmur...@xxxxxxxxxxxxxxx> escribió:
>> En *Mon, *Oct 31, 2011 en 3:51 PM, *Efi *Merdler-*Kravitz
>>
>> <efi.merd...@xxxxxxxxx> escribió:
>> > El problema más grande es la imagen sola que estoy intentando cargar, es
>> > #uno 250*K *gif imagen que consigue *inflated a casi 11MB.
>>
>> > Cómo  sugieres bajar este número?
>>
>> Uno se acerca sería para utilizar una imagen de resolución baja.
>>
>> > *BTW Por qué las imágenes consiguen *inflated tanto cuándo cargado a la memoria ?
>>
>> imágenes de GIF utilizan un *technique sabido como "compresión", cuando hacer *JPEGs, *PNGs,
>> vídeos de MPEG, MP3 y *OGG archivos de audio, *etc. A *render la imagen, necesita ser *decompressed. "250*K" es un *meaningless valor cuándo viene
>> a medir consumo de memoria.
>>
>> *Heap El Uso es una reflexión del número de *pixels (resolución) y la profundidad
>> de bit de cada *pixel (*RGB_565 es 2 *bytes/*pixel; *RGB_888 es 3
>> *bytes/*pixel). Incluso si suponemos que estás utilizando *RGB_888, 11MB todavía
>> requeriría más *pixels que #uno 1080*p exhibición (1920*x1080*x3 es sobre
>> 6MB). Aquello sugiere que quizás estás utilizando una imagen mucha demasiado grande.
>>
>> --
>> Mark *Murphy (un *Commons Guy)*http://*commonsware.*com|*http://*github.*com/*commonsguyhttp://*commonsware.*com/*blog|*http://*twitter.*com/*commonsguy
>>
>> _*Android Programación *Tutorials_ Versión 4.0 Disponible!
>
> --
> Recibiste este mensaje porque eres *subscribed al *Google
> Grupos "*Android *Developers" grupo.
> A correo a este grupo, envía *email a *android-developers@xxxxxxxxxxxxxxxx
> A *unsubscribe de este grupo, envía *email a *android-*developers+unsubscribe@xxxxxxxxxxxxxxxx
> 
> Puesto que más opciones, visita este grupo en
> *http://grupos.*google.*com/Grupo/*android-*developers?*hl=*en

-- 
Recibiste este mensaje porque eres *subscribed al *Google
Grupos "*Android *Developers" grupo.
A correo a este grupo, envía *email a *android-developers@xxxxxxxxxxxxxxxx
A *unsubscribe de este grupo, envía *email a *android-*developers+unsubscribe@xxxxxxxxxxxxxxxx

Puesto que más opciones, visita este grupo en
*http://grupos.*google.*com/Grupo/*android-*developers?*hl=*en

Even then, this isn't really an Android specific question.  It's more
of a Java specific question, or a software engineering related
question.  However, it might be nice to include a bit of information
about garbage collection and memory reclaiming as it relates to
Android.

kris

On Mon, Oct 31, 2011 at 5:00 PM, Efi Merdler-Kravitz
<efi.merdler@xxxxxxxxx> wrote:
> Thanks. Working. Any chance to add a chapter on memory management in
> your online book - "Tuning Android Applications" ?
>
>
>
> On Oct 31, 10:17 pm, Mark Murphy <mmur...@xxxxxxxxxxxxxxx> wrote:
>> On Mon, Oct 31, 2011 at 3:51 PM, Efi Merdler-Kravitz
>>
>> <efi.merd...@xxxxxxxxx> wrote:
>> > The biggest problem is the single image that I'm trying to load, it's
>> > a 250K gif image that gets inflated to almost 11MB.
>>
>> > How would you suggest lowering this number?
>>
>> One approach would be to use a lower-resolution image.
>>
>> > BTW why images get inflated so much when loaded into the memory ?
>>
>> GIF images use a technique known as "compression", as do JPEGs, PNGs,
>> MPEG videos, MP3 and OGG audio files, etc. To render the image, it
>> needs to be decompressed. "250K" is a meaningless value when it comes
>> to measuring memory consumption.
>>
>> Heap usage is a reflection of the number of pixels (resolution) and
>> the bit depth of each pixel (RGB_565 is 2 bytes/pixel; RGB_888 is 3
>> bytes/pixel). Even if we assume that you are using RGB_888, 11MB would
>> still require more pixels than a 1080p display (1920x1080x3 is about
>> 6MB). That suggests that you are perhaps using a much too large image.
>>
>> --
>> Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy
>>
>> _Android Programming Tutorials_ Version 4.0 Available!
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@xxxxxxxxxxxxxxxx
> To unsubscribe from this group, send email to
> android-developers+unsubscribe@xxxxxxxxxxxxxxxx
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@xxxxxxxxxxxxxxxx
To unsubscribe from this group, send email to
android-developers+unsubscribe@xxxxxxxxxxxxxxxx
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

<Anterior por Tema] Tema Actual [Siguiente por Tema>