Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!mailrus!tut.cis.ohio-state.edu!snorkelwacker!apple!sun-barr!newstop!sun!kimba!hvr From: hvr@kimba.Sun.COM (Heather Rose) Newsgroups: comp.windows.x Subject: Re: XView and image display Keywords: XView, Sun Message-ID: <131499@sun.Eng.Sun.COM> Date: 9 Feb 90 00:23:38 GMT References: <1990Feb6.202148.14508@elroy.jpl.nasa.gov> Sender: news@sun.Eng.Sun.COM Reply-To: hvr@sun.UUCP (Heather Rose) Distribution: na Organization: Sun Microsystems, Mountain View Lines: 33 In article <1990Feb6.202148.14508@elroy.jpl.nasa.gov> alan@judy.Jpl.Nasa.Gov (Alan S. Mazer) writes: >Has anyone out there successfully displayed an image in OpenWindows without >using pw_ calls? I can't find any examples that do this and everything I've >tried simply core dumps. If you have, would you PLEASE send (or post) sample >code? Thanks. Just use XPutImage(display, xid, gc, image, src_x, src_y, dst_x, dst_y, width, height); i.e. canvas = xv_create(frame, CANVAS, CANVAS_REPAINT_PROC, canvas_repaint, CANVAS_X_PAINT_WINDOW, TRUE, ... canvas_repaint(canvas, pw, display, xid, xrects) Canvas canvas; Xv_Window pw; Display *display; Window xid; Xv_xrectlist *xrects; { ... XPutImage(display, xid, gc, image, 0, 0, x, y, w, h); ... Regards, Heather