[JDEV] Avatar dimensions & disconnect detail
jens at mac.com
Fri Sep 7 16:35:44 CDT 2001
Two more issues that have come up in the course of my implementing the
(1) The hardcoded 48x48 dimensions. In my client the original picture of
the user is 64x64 (the native resolution of the photos the OS X Mail app
uses.) When I scale this down to 48x48 to send over Jabber and then
display it on the receiving end at 32x32 (the native resolution my
client uses), it gets a really ugly case of the jaggies. (Yes, even with
bicubic scaling.) The JPEG compression isn't the issue; I tried it
uncompressed and the results were just as bad.
My current thinking is that maybe we should not require exact dimensions
but let each client send its preferred size (subject to the 8k-of-data
constraint). The receiver can then scale the image if necessary. We can
still recommend 48x48 as the preferred dimensions if the client doesn't
have any other constraints (i.e. if it's shrinking down a much larger
Or we could have some scheme for providing multiple representations of
different dimensions, but this gets a lot more complex.
(2) There's a small glitch with the current proposal, and it's partly my
fault. When a client disconnects, its watchers get a <presence
type='unavailable'> element generated by the Jabber server with a
message of "Disconnected". This obviously doesn't contain any
jabber:x:avatar extension, so according to the current protocol it will
cause watchers to clear the current cached buddy icon. Then they end up
having to fetch it again the next time that person comes online. The
best way around this, I think, is to ignore a missing jabber:x:avatar in
a presence element whose type is 'unavailable'.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 1804 bytes
Desc: not available
More information about the JDev