[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference bulova::decw_jan-89_to_nov-90

Title:DECWINDOWS 26-JAN-89 to 29-NOV-90
Notice:See 1639.0 for VMS V5.3 kit; 2043.0 for 5.4 IFT kit
Moderator:STAR::VATNE
Created:Mon Oct 30 1989
Last Modified:Mon Dec 31 1990
Last Successful Update:Fri Jun 06 1997
Number of topics:3726
Total number of notes:19516

2841.0. "Pixmaps and off-screen memory" by EVOAI2::DAN_M (Maya DAN) Thu May 31 1990 05:01

   
    Questions about the allocation of Pixmaps 
    
    I want to allocate a pixmap with given width and height, using the
    XCreatePixmap function. This pixmap is supposed to be allocated
    into the off-screen memory managed by the server.
    
    What happens if the off-screen memory is not large enough (too many
    pixmaps have already been created, or the size of my pixmap is to
    important for the available memory) ?  I have been told that the
    pixmap is then placed into the  memory of the station, or on disk.
    Is it correct ?, and what happens  if I am on a X Terminal, without
    disk ?.
    
    Is it possible to test the available memory before making my request
    to XCreatePixmap?
    
    
    Many thanks 
    Maya

T.RTitleUserPersonal
Name
DateLines
2841.1STAR::KLEINSORGEFred Kleinsorge, VMS DevelopmentThu May 31 1990 12:5515
    
    Nope.  Not even as a hint.  The asynchronous connection between the
    client and server would make any such inquiry inherently unreliable.
    
    What happens is that your PIXMAP will be loaded into offscreen memory
    (if there is such a thing) in a server dependent fashion.  This may
    cause other PIXMAPs to be: Swapped to main memory, written to disk,
    thrown away completely.  Or, your request may simply fail.  It all
    really depends on the server and to some extent the hardware.  And
    even knowing the total "offscreen memory" can't tell you if your
    PIXMAP would fit - since you also would need to know things about
    offscreen memory organization, server design (for the specific server)
    and offscreen memory fragmentation.
    
    
2841.2DECWIN::FISHERPrune Juice: A Warrior's Drink!Thu May 31 1990 18:5511
On DEC VMS servers, you can allocate pixmaps up to a certain absolute size
(roughly the size of the screen on a GPX, for example).  If your pixmaps don't
all fit in, they are swapped to server's process virtual memory.  I don't know
of any case where a pixmap is arbitrarily thrown away.  That would be a violation
of the X protocol.

To find out you have to allocate it.  Do an XSync, establish an error handler,
do the alloc, do another XSync.  If the error handler was not called, the pixmap
was allocated successfully.

Burns