linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: fb_imageblit semantic
@ 2003-03-14 10:18 Petr Vandrovec
  2003-03-14 10:40 ` Geert Uytterhoeven
  0 siblings, 1 reply; 17+ messages in thread
From: Petr Vandrovec @ 2003-03-14 10:18 UTC (permalink / raw)
  To: Geert Uytterhoeven; +Cc: James Simmons, Linux Frame Buffer Device Development

On 14 Mar 03 at 10:22, Geert Uytterhoeven wrote:
> On Thu, 13 Mar 2003, Petr Vandrovec wrote:
> > Why do you pass image.depth == 16 (or 24 or 32) to fb_imageblit
> > when logo image is in reality always 8bpp, as quick look at 
> > cfb_imageblit revealed?
> 
> Should indeed be 8.
> 
> > Should I just assume that image.depth == 1 means that data are
> > 1bpp with fgcol/bgcol valid, and all other depths mean 8bpp
> > input?
> 
> This was changed from 1 to 0 in James' latest tree.

WTF? Color depth 0 means that whole picture is single-color, and
imageblit degenerates to rectfill in such case. Please, either
use 'depth' as source image color depth, or do not name it depth.
                                                Petr Vandrovec
                                                



-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 17+ messages in thread
* Re: fb_imageblit semantic
@ 2003-03-17 12:25 Petr Vandrovec
  2003-03-17 12:40 ` Geert Uytterhoeven
  2003-03-17 13:02 ` Antonino Daplas
  0 siblings, 2 replies; 17+ messages in thread
From: Petr Vandrovec @ 2003-03-17 12:25 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: James Simmons, Linux Frame Buffer Device Development, adaplas

On 17 Mar 03 at 13:18, Geert Uytterhoeven wrote:
> 
> That depends... How do we draw the monochrome penguin? Using image->depth is 1
> or 8? The latter (current method) is slower, since we need to expand the
> monochrome logo to 8-bit first, and (usually) compress it to 1-bit in the fbdev
> driver afterwards.

As far as I can see, it gets monochromatic logo and converts it to
8bpp format ;-) (fb_set_logo, needs_logo = 1 or ~1) And then imageblit
converts it back to 1bpp.
 
> And perhaps we may want to draw 32-bit ARGB images later?
> 
> So I see the following possible valid values for image->depth:
>   - 8 (logo with up to 256 colors and LUT)
>   - optional 1 (monochrome logo, if we don't want to expand?)
>   - optional 32 (ARGB image, dithering left to the driver?)

I still do not understand 'if we don't want to expand'. This forces too
much knowledge on upper layer, as far as I can tell.
                                                    Petr Vandrovec
                                                    



-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 17+ messages in thread
* Re: fb_imageblit semantic
@ 2003-03-17 10:40 Petr Vandrovec
  2003-03-17 12:07 ` Antonino Daplas
  0 siblings, 1 reply; 17+ messages in thread
From: Petr Vandrovec @ 2003-03-17 10:40 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: James Simmons, Linux Frame Buffer Device Development, adaplas

On 17 Mar 03 at 11:31, Geert Uytterhoeven wrote:
> On 17 Mar 2003, Antonino Daplas wrote:
> > As Geert said, it's not just trivial, but logical to split fb_imageblit
> > into two.
> 
> So, are we gonna split it? This will also make hardware acceleration support
> more clean. E.g. most sbus drivers do color expansion in hardware, and fall
> back to cfb_imageblit() for the logo.
> 
> > > OK, so rule is that if depth=0, input is 1bpp with palette in bgcol/fgcol,
> > > while if depth != 0, then palette is in info->pseudo_palette ?
> > 
> > Yes.  You can also say that if image->depth != var->bits_per_pixel, do
> > color expansion or reduction, whatever the case may be.
> 
> Hmmm... Note that image->depth can be larger than 8, while the image data is
> still 8-bit. This is an inconsistency.

image->depth for logo must change to 8. Or remove depth completely after
splitting imageblit to paintchar & paintlogo, as currently depth is
useless anyway: target format is defined by framebuffer layout, not
by image->depth, and source format is hardwired to the code.
                                                        Petr Vandrovec
                                                        vandrove@vc.cvut.cz



-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 17+ messages in thread
* Re: fb_imageblit semantic
@ 2003-03-14 10:52 Petr Vandrovec
  2003-03-16 23:00 ` Antonino Daplas
  0 siblings, 1 reply; 17+ messages in thread
From: Petr Vandrovec @ 2003-03-14 10:52 UTC (permalink / raw)
  To: Geert Uytterhoeven; +Cc: James Simmons, Linux Frame Buffer Device Development

On 14 Mar 03 at 11:40, Geert Uytterhoeven wrote:
> On Fri, 14 Mar 2003, Petr Vandrovec wrote:
> > On 14 Mar 03 at 10:22, Geert Uytterhoeven wrote:
> > > On Thu, 13 Mar 2003, Petr Vandrovec wrote:
> > > > Why do you pass image.depth == 16 (or 24 or 32) to fb_imageblit
> > > > when logo image is in reality always 8bpp, as quick look at 
> > > > cfb_imageblit revealed?
> > > 
> > > Should indeed be 8.
> > > 
> > > > Should I just assume that image.depth == 1 means that data are
> > > > 1bpp with fgcol/bgcol valid, and all other depths mean 8bpp
> > > > input?
> > > 
> > > This was changed from 1 to 0 in James' latest tree.
> > 
> > WTF? Color depth 0 means that whole picture is single-color, and
> > imageblit degenerates to rectfill in such case. Please, either
> > use 'depth' as source image color depth, or do not name it depth.
> 
> It's 0 (expand [bf]gcol) to differentiate from 1 (copy monochrome).
> 
> Splitting imageblit into separate routines for both operations would be
> trivial, though.

There is no such thing as copy monochrome if target is not monochrome,
you have to put palette somewhere. If you'll look at cfb_imageblit,
you'll find that there is already defined way to do that: code uses
artifically created 256 entry pseudopalette... If target is monochrome,
it just copies data. If target is not monochrome, it has somehow expand
data to fit to screen format. Nothing differs between font painting
and copying 1bpp bitmap to Xbpp display. 

OK, so rule is that if depth=0, input is 1bpp with palette in bgcol/fgcol,
while if depth != 0, then palette is in info->pseudo_palette ?
                                            Thanks,
                                                Petr Vandrovec
                                                vandrove@vc.cvut.cz
                                                



-------------------------------------------------------
This SF.net email is sponsored by:Crypto Challenge is now open! 
Get cracking and register here for some mind boggling fun and 
the chance of winning an Apple iPod:
http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0031en

^ permalink raw reply	[flat|nested] 17+ messages in thread
* FBdev updates.
@ 2003-02-20  1:09 James Simmons
  2003-02-20 15:02 ` Dave Jones
  0 siblings, 1 reply; 17+ messages in thread
From: James Simmons @ 2003-02-20  1:09 UTC (permalink / raw)
  To: Linux Kernel Mailing List; +Cc: Linux Fbdev development list


New updates to the fbdev layer. You can grab the diff from 

http://phoenix.infradead.org/~jsimmons/fbdev.diff.gz

or do a pull

	bk pull http://gkernel.bkbits.net/fbdev-2.5

This will update the following files:

 drivers/video/maxinefb.h                   |   37 
 drivers/video/pm2fb.h                      |  218 ---
 drivers/video/pm3fb.h                      | 1284 --------------------
 drivers/video/pmag-ba-fb.h                 |   24 
 drivers/video/pmagb-b-fb.h                 |   32 
 drivers/video/sstfb.h                      |  355 -----
 arch/mips64/Kconfig                        |    4 
 arch/ppc/syslib/prom.c                     |    3 
 arch/ppc/syslib/prom_init.c                |   28 
 arch/ppc64/kernel/prom.c                   |   27 
 drivers/char/vt.c                          |    8 
 drivers/video/Kconfig                      |   17 
 drivers/video/Makefile                     |    3 
 drivers/video/aty/atyfb.h                  |   86 -
 drivers/video/aty/atyfb_base.c             | 1804 ++++++++++++++---------------
 drivers/video/aty/mach64_accel.c           |   51 
 drivers/video/aty/mach64_ct.c              |  356 +++--
 drivers/video/aty/mach64_cursor.c          |    4 
 drivers/video/aty/mach64_gx.c              |   18 
 drivers/video/aty128fb.c                   |  162 +-
 drivers/video/cfbcopyarea.c                |   42 
 drivers/video/cfbfillrect.c                |   12 
 drivers/video/cfbimgblt.c                  |  100 -
 drivers/video/console/fbcon.c              |  333 -----
 drivers/video/console/fbcon.h              |    3 
 drivers/video/console/newport_con.c        |   69 -
 drivers/video/console/vgacon.c             |  673 +++++-----
 drivers/video/fbmem.c                      |  306 ++--
 drivers/video/fbmon.c                      |    3 
 drivers/video/hgafb.c                      |    9 
 drivers/video/i810/i810.h                  |    9 
 drivers/video/i810/i810_accel.c            |  150 +-
 drivers/video/i810/i810_main.c             |  486 ++-----
 drivers/video/i810/i810_main.h             |   14 
 drivers/video/logo/Kconfig                 |   67 +
 drivers/video/logo/Makefile                |   27 
 drivers/video/logo/logo.c                  |  100 +
 drivers/video/logo/logo_dec_clut224.ppm    | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_linux_clut224.ppm  | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_linux_mono.pbm     |  202 +++
 drivers/video/logo/logo_linux_vga16.ppm    | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_mac_clut224.ppm    | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_parisc_clut224.ppm | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_sgi_clut224.ppm    | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_sun_clut224.ppm    | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_superh_clut224.ppm | 1603 +++++++++++++++++++++++++
 drivers/video/logo/logo_superh_mono.pbm    |  202 +++
 drivers/video/logo/logo_superh_vga16.ppm   | 1603 +++++++++++++++++++++++++
 drivers/video/maxinefb.c                   |    2 
 drivers/video/modedb.c                     |    8 
 drivers/video/neofb.c                      |   81 -
 drivers/video/pm2fb.c                      |    2 
 drivers/video/pm3fb.c                      |    3 
 drivers/video/pmag-ba-fb.c                 |    2 
 drivers/video/pmagb-b-fb.c                 |    2 
 drivers/video/radeonfb.c                   |    1 
 drivers/video/riva/fbdev.c                 |  323 ++---
 drivers/video/riva/nv_driver.c             |  156 ++
 drivers/video/riva/rivafb.h                |    2 
 drivers/video/sgivwfb.c                    |  192 ++-
 drivers/video/skeletonfb.c                 |    6 
 drivers/video/sstfb.c                      |   14 
 drivers/video/tdfxfb.c                     |    6 
 drivers/video/tgafb.c                      |    2 
 drivers/video/tridentfb.c                  |    2 
 drivers/video/vga16fb.c                    |  127 +-
 include/linux/fb.h                         |   19 
 include/linux/linux_logo.h                 | 1435 -----------------------
 include/video/mach64.h                     |   61 
 include/video/maxinefb.h                   |   37 
 include/video/pm3fb.h                      | 1284 ++++++++++++++++++++
 include/video/pmag-ba-fb.h                 |   24 
 include/video/pmagb-b-fb.h                 |   32 
 include/video/sgivw.h                      |   40 
 include/video/sstfb.h                      |  355 +++++
 include/video/vga.h                        |   16 
 scripts/Makefile                           |    4 
 scripts/pnmtologo                          |binary
 scripts/pnmtologo.c                        |  498 ++++++++
 79 files changed, 20264 insertions(+), 6227 deletions(-)

through these ChangeSets:

<jsimmons@maxwell.earthlink.net> (03/02/19 1.913.1.3)
   [FBDEEV] Need to add support to build pnmtologo.

<jsimmons@maxwell.earthlink.net> (03/02/19 1.913.1.1)
   Removed obsolete functions in fbcon.c and re-enabled mapping console(s) to a framebuffer device. A few compile fixes for rivafb and using standard macros for vgacon.c.

<jsimmons@maxwell.earthlink.net> (03/02/16 1.913)
   [FBDEV] Data in struct fb_image is now const.
   
   [FBDEV] Updates to the logo code. We seperated it into two functions.
   
   [I810 FBDEV] Updates to the driver. PCI hooks for PCI supsend and resume to save the AGP GART mapping during power saving.
   
   [ATY 128] Add proper support for two graphics cards. Also added support for two more models of the Rage 128.
   
   [SGIVW FBDEV] Updates for the SGI Visual Workstation framebuffer.
   

<jsimmons@maxwell.earthlink.net> (03/02/13 1.910)
   [LOGO] New better logo code. 
   
   [FBDEV] Moved a few more header files.

<jsimmons@maxwell.earthlink.net> (03/02/11 1.909)
   [FBCON] Removal of useless code.

<jsimmons@maxwell.earthlink.net> (03/02/11 1.906)
   [ATY FBDEV] Reversed mobilty patches. They busted every other card.  

<jsimmons@maxwell.earthlink.net> (03/02/09 1.900)
   [ATY FBDEV] Updates to support Rage Mobility Chipstes.

<jsimmons@maxwell.earthlink.net> (03/01/30 1.899)
   [RIVA FBDEV] SUpprot Directcolor mode. Needed for some cards.

<jsimmons@kozmo.(none)> (03/01/28 1.897)
   [NEOMAGIC FBDEV] Fix to work with no 21xx versions of the chip.

<jsimmons@maxwell.earthlink.net> (03/01/28 1.889.52.3)
   [RADEON FBDEV] Add cursor support. Now the cursor is back.
   [RIVA FBDEV] Added support for interlace mode and are now using TRUECOLOR instead of DIRECTCOLOR. Setting the graphics card in DIRECTCOLOR confusses the X server.

<jsimmons@maxwell.earthlink.net> (03/01/26 1.889.52.2)
   Accel rountines pass in constant data into each function. The reason being was some of the code in the upper layers depended on the data being passed to the low level function not be altered because the upper layers was altering the data themselves.
   
   Pan display fix for fbcon.c. p->vrow needed to be updated.
   
   PPC build fix for fbmon.c
   
   I810 fbdev updates. 

<jsimmons@maxwell.earthlink.net> (03/01/17 1.889.52.1)
   [GENERIC ACCELERATION] Fixed the generic image drawing function tfor 64 bit machines.
   
   [RIVA FBDEV] The cursor and imageblit functions have been fixed.

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2003-03-17 14:48 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-03-14 10:18 fb_imageblit semantic Petr Vandrovec
2003-03-14 10:40 ` Geert Uytterhoeven
  -- strict thread matches above, loose matches on Subject: below --
2003-03-17 12:25 Petr Vandrovec
2003-03-17 12:40 ` Geert Uytterhoeven
2003-03-17 13:02 ` Antonino Daplas
2003-03-17 13:47   ` Geert Uytterhoeven
2003-03-17 14:24     ` Antonino Daplas
2003-03-17 14:46       ` Geert Uytterhoeven
2003-03-17 10:40 Petr Vandrovec
2003-03-17 12:07 ` Antonino Daplas
2003-03-17 12:18   ` Geert Uytterhoeven
2003-03-17 13:01     ` Antonino Daplas
2003-03-14 10:52 Petr Vandrovec
2003-03-16 23:00 ` Antonino Daplas
2003-03-17 10:31   ` Geert Uytterhoeven
2003-02-20  1:09 FBdev updates James Simmons
2003-02-20 15:02 ` Dave Jones
2003-02-20 18:29   ` Petr Vandrovec
2003-02-21  0:24     ` Antonino Daplas
2003-03-03 20:35       ` [Linux-fbdev-devel] " Petr Vandrovec
2003-03-04 21:29         ` Jurriaan
2003-03-09 21:29           ` Petr Vandrovec
2003-03-09 22:27             ` Antonino Daplas
2003-03-09 22:54               ` Petr Vandrovec
2003-03-13 22:23                 ` fb_imageblit semantic Petr Vandrovec
2003-03-14  9:22                   ` Geert Uytterhoeven

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).