Page 1 of 1

Question; HUD loading mult images; limits?

Posted: Tue Jan 19, 2010 7:13 am
by JeffBTX
Rather than ramble on like I usually do (see... there... I'm doing it...)

... just basic questions... you have a HUD OXP that loads multiple images: Is there a specific limit to how many and what size?

Is there an upper limit that should be avoided? (there will be a PRACTICAL or LIKELY limit that is far short of any absolute technical limit).

Or... do ALL of the images get "integrated" somehow in one memory block? (just thought I would ask...)

(IE answers might be "Don't load 500 1680x1050 images in your HUD OXP, that will crash the game" ... or ... "No, through clever coding, if you have say, 10 images that make up a HUD, each with their own alpha and opaque and semitransparent layers, Oolite reads them in, analyzes them, processes them, and turns all of those layers into one integrated image, internally.")

====

Okay some rambling, to show where I'm coming from.

(a) (or, "premise") I experimented with 4 images once to see what would happen, and mess around with the order-of-loading; the 128x128 semitransparent PNG that I use for my contrast disk / crosshair (1 layer, 1 alpha); and 3 opaque squares; red, green and blue that overlapped. So I know that "many images" to make up a cockpit "in pieces" or "piece by piece" is possible.

(1) Recently I attempted to use a RayTracer to make a high quality cockpit. That was abandoned because targeting brackets show up in FRONT of HUD images, even opaque ones. That used 2 images... a 128x128 crosshair / contrast disk PNG, and a 1680x1050 image with opaqueness that made up the cockpit ... including dashboard and struts.

(2) I have another idea now. BUT I am not that well practiced (yet) in using Paint Shop Pro (PSP 5.03) on ONE image with multiple alphas and masks. It is easier (for now) to make different images, and load them in. It's kind of hard to explain. I will continue to practice w/ masks, but in PSP they are kind of hard to use... "cumbersome".

... but in the meantime, if Oolite is running at 1680x1050, and a HUD loads several 1680x1050 images, am I approaching something that is "bad"? (inefficient, yes, but I'm concerned about crashing).