[U-Boot] [PATCH 2/2] cmp_bmp: allow negative X, Y values for display command

Detlev Zundel dzu at denx.de
Fri Aug 27 13:46:43 CEST 2010


Hi Timur,

> The 'bmp display' command accepts optional X and Y values for the position
> of the image to be displayed.  Change the code which parses the command line
> to accept negative values.
>
> This feature is useful if you want to use a frame buffer for the console, and
> you want a banner displayed on the top of the screen that never scrolls off.
> This can be accomplished by declaring that the width and height of the video
> screen is smaller than it really is, and then drawing an image in the
> undeclared area.
>
> For example, if you have 1280x1024 monitor, and you want to display a banner
> on the top of the screen that's 100 pixels tall, then video_hw_init() should
> say that display is really 1280x924, and then the banner should be drawn at
> position (0, -100).

Ugh.  I have to admit that I really dislike this patch.  What you
effectively do is to erase the "aboluteness" of coordinates.  Instead of
the current 1:1 correspondence between a pixel coordinate and its
location on the physical display, you introduce virtual coordinates
without any possibility to inquire about the virtual coordinate system
in use.

Currently if we display an image at (0, 0) we can be sure that it
appears at the edge of the display.  With your system one cannot tell
without knowing the complete context.

Can't you come up with a scheme which does not destroy this valuable
property of our coordinates?

Cheers
  Detlev

-- 
When you  loosen yourself from  all the obvious delusions  - religion,
ideology,  Communism - you're  still left  with the  myth of  your own
goodness. Which is the final delusion.
                                          -- Philip Roth
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de


More information about the U-Boot mailing list