Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!tut.cis.ohio-state.edu!ucbvax!EE.ECN.PURDUE.EDU!bevis From: bevis@EE.ECN.PURDUE.EDU (Jeff Bevis) Newsgroups: comp.sys.amiga Subject: Re: Lattice C Power Windows Message-ID: <8912030300.AA24366@en.ecn.purdue.edu> Date: 3 Dec 89 03:00:55 GMT References: <[2577758d:2917]comp.sys.amiga@tronsbox.UUCP> Sender: daemon@ucbvax.BERKELEY.EDU Organization: Purdue University Engineering Computer Network Lines: 47 In article <[2577758d:2917]comp.sys.amiga@tronsbox.UUCP>, tron1@tronsbox.UUCP (HIM) writes: >I am attempting to render a screen/window combo. These products have worked >well for me together before , but can't seem to get it straight now. > >The problem is in custom images for gadgets. I used PW2.5 to set up the >gadgets using DpaintII brushes, and In power windows it looked GREAT. > >When the Code generated is compiled into the sampole program they give you , >the gadget images are hopelessly munged. The gadgets ARE there , and If I do >this without the custom imagrey , it works right. > When PW writes its code for you, it declares all of its image data like this: USHORT ImageDataXX { 0x0000,0xffff,0x0000,0xffff }; But for blit'able imagery (as is used in Intuition Image structs), you must place the image data in chip memory. Under Lattice 5.04, this is as simple as modifying the declarations with the addition of the "chip" keyword. USHORT chip ImageDataXX { 0x0000,0xffff,0x000,0xffff }; If you've got a huge data file, full of lots of gadgetry (with images), just use your editor to do a search and replace of USHORT ImageData with USHORT chip ImageData and all will be fine. It's a nuisance, but workable. Certainly, it is still better than designing gadgets & images by hand!! As an aside, I have found that DPaint III pics cause problems for the PowerWindows "screen palette" function -- loading a DPIII pic's color set into the current screen DOES NOT SEEM TO WORK. Instead, the program will hang (not crash). Be forewarned. PW2.5 is begging to be revised for these newer, modern times. +--------------------------------+--------------------------------------------+ | Jeff Bevis | "But I don't like spam!" | | bevis@en.ecn.purdue.edu | Give me Amiga or nothing at all. | +--------------------------------+--------------------------------------------+