O HAI THIS BLOG PURPZIEZ 2 B UZED AZ MAH PLESIOUS MEM. :)

2009/02/27

NetSurf / FrameBuffer

#netsurfがframbuffer portで盛り上がっていたので,モニョる. :DDD
 02/26 21:01:19 hiyuh
what does NETSURF_FB_FRONTEND=able mean?
02/26 21:01:50 hiyuh
runtime linux/sdl detection?
02/26 21:02:29 tlsa
to pick whether to build nsfb for the linux, able or other framebuffer
02/26 21:02:54 kyllikki
the list is now able, sdl, linux and vnc
02/26 21:03:16 kyllikki
sdl, linux and vnc are mostly what you will be interested in

02/26 21:24:47 hiyuh
nsfb-{sdl,linux} doesn't work here. :(
02/26 21:26:09 rjek
You won't get much help without details :)
02/26 21:26:54 hiyuh
http://dev.gentoo.gr.jp/~hiyuh/misc/nsfb-linux-r6625-fsckedup.jpg
 02/26 21:27:11 hiyuh
color is fscked up completely. :)
02/26 21:27:22 rjek
Oh, an endianess problem.
02/26 21:27:30 rjek
TTOTD: Don't use big-endian machines.
02/26 21:27:33 rjek
:)
02/26 21:28:09 hiyuh
keyboard/mouse doesn't work too, so I did force powerdown this
powerbook. :DDD
02/26 21:29:22 hiyuh
tested only x86 boxes?
02/26 21:29:27 rjek
And ARM.
02/26 21:29:33 rjek
Extensively on ARM, in fact.
02/26 21:29:39 hiyuh
ah, k
02/26 21:31:10 jmb
awesome
02/26 21:31:17 jmb
kyllikki: that rocks
02/26 21:41:02 jmb
hiyuh: I assume keyboard/mouse work correctly under sdl?
02/26 21:43:45 jmb
as for endianness, it's likely in the plotters
02/26 21:45:18 hiyuh
jmb: sadly, nope. sdl's one said "Unable to init SDL: Unable to open
mouse" then segv immediately (was tested on X/fbconsole).
02/26 21:45:29 jmb
hiyuh: oddness
02/26 21:46:59 jmb
hiyuh: I assume other SDL apps work?
02/26 21:47:16 hiyuh
jmb: let me check
02/26 21:47:51 jmb
hiyuh: because the SDL_Init() call we have is entirely standard :)
02/26 21:51:09 hiyuh
jmb: it works on X, but it doesn't work on fb. maybe, causes of
"sdl's ones didn't work on X/fbconsole" are different.
02/26 21:52:13 jmb
hiyuh: right
02/26 21:57:48 hiyuh
jmb: I guess X blocks mouse device access from SDL when I was on
fbconsole, I'll check w/o running X (no VT switch).
02/26 21:57:50 jmb
there. updated the application
02/26 21:58:02 jmb
hiyuh: wouldn't surprise me
02/26 21:58:09 hiyuh
yup, bbl

02/27 00:17:11 hiyuh
jmb: cause of SDL_init error comes from my udev rules were
fscked up, sorry. even though, sdl's one still rocks. :)
http://dev.gentoo.gr.jp/~hiyuh/misc/nsfb-sdl-r6625-fsckedup-270.jpg
 02/27 00:18:34 Kinnison
hiyuh: are colours in web pages wrong too?
02/27 00:18:40 Kinnison
Or just the furniture?
02/27 00:21:05 hiyuh
nope, it can not show any page ATM.
02/27 00:21:51 Kinnison
Odd
02/27 00:21:56 Kinnison
why not?
02/27 00:23:24 tlsa
Kinnison: web page colours were wrong in is photo:
http://dev.gentoo.gr.jp/~hiyuh/misc/nsfb-linux-r6625-fsckedup.jpg
02/27 00:27:06 Kinnison
hmm
02/27 00:27:39 Kinnison
presumably this is kyllikki needing to support endianness stuff in
his plotters?
02/27 00:28:54 hiyuh
fb_plotters_ablend()?
02/27 00:30:37 Kinnison
that's the alphablend isn't it?
02/27 00:31:16 hiyuh
I guess. it calculates r/g/b.
02/27 00:50:09 kyllikki
hi
02/27 00:50:14 tlsa
re k
02/27 00:50:59 kyllikki
right for big endien the least invasive way is to have different
plotter c files built
02/27 00:51:44 kyllikki
e.g. fb_32bpp_plotters_be.c
02/27 00:52:14 kyllikki
because although the machines words are BE it appears the framebuffer
display is LE
02/27 00:52:39 kyllikki
I suppose I could make it generic but...
02/27 00:52:44 rjek
How much of the code is actually different?
02/27 00:52:47 rjek
Might #ifdefing be better?
02/27 00:53:08 kyllikki
rjek: I really didnt want a load more #ifdeffery
02/27 00:53:20 rjek
Well, if large bits of the function will be different, I agree.
02/27 00:53:30 kyllikki
I am thinking of ways to remove the existing ifdefery
02/27 00:53:52 kyllikki
rjek: its every time an output colour is computed
02/27 00:54:04 kyllikki
so its not everso often
02/27 00:57:04 kyllikki
no, i see it
02/27 00:57:08 kyllikki
I can generalise it
02/27 00:57:24 kyllikki
in fact i ought to
02/27 01:02:11 tlsa
is it easy to add the rest of those pointers?
02/27 01:06:42 kyllikki
what #define can i use to determine endiness at compile time?
02/27 01:09:55 hiyuh
? http://dev.gentoo.gr.jp/~hiyuh/misc/netsurf-gifread-try2fixonBE.diff
02/27 01:11:02 kyllikki
cool
02/27 01:14:53 kyllikki
try that?
02/27 01:15:04 kyllikki
I *think* my shifts are right
02/27 01:15:50 kyllikki
you get to test if #if __BYTE_ORDER == __BIG_ENDIAN is right
02/27 01:16:45 hiyuh
ACK
02/27 01:19:38 *
kyllikki waits paitently

02/27 01:29:08 hiyuh
lol
02/27 01:29:09 hiyuh
http://dev.gentoo.gr.jp/~hiyuh/misc/nsfb-sdl-r6635-onX-fsckedup.jpg
 02/27 01:29:46 hiyuh
mouse/keyboard works. :)
02/27 01:29:49 kyllikki
hmm thats 32bpp?
02/27 01:30:12 hiyuh
dunno, just run nsfb on X.
02/27 01:30:23 kyllikki
well 32bpp is the default
02/27 01:32:49 hiyuh
let me try -linux.

02/27 03:39:52 hiyuh
on 32bpp nvidiafb, -linux shows red screen, keyboard/mouse doesn't
work and cpu usage goes 100% then I did force poweroff.
02/27 03:40:01 hiyuh
FYI, generic ppc machine uses offb which is 8bpp by default.
02/27 03:40:05 hiyuh
kyllikki: ^^
02/27 03:40:39 kyllikki
right, the 8bpp plotters may indeed be funted
02/27 03:41:07 kyllikki
hiyuh: I will take a look, maybe later maybe morrow
02/27 03:41:15 kyllikki
tired atm
02/27 03:41:20 hiyuh
k, thx
02/27 03:41:24 kyllikki
np
つーわけで,次回に持ち越し.
今のところ,一番まともなのは-sdlを32bpp nvidiafbで動かす場合かな.
nouveauの中の人は{nvidia,riva}fbはstateがゴチャゴチャになるからofonlyにしろって言うし,offbは32bppにならねーし,どーすっか.


で,NETSURF_FB_FONTLIB=freetypeにしたら,FTC_CMapCache_Lookup()でSEGVるのを発見.
gcc-4.3.3のbugかもしれんので,熟成の方向で. :P

0 件のコメント: