Path: utzoo!utgpu!cunews!bnrgate!brchh104!brchs1!bnr.ca!rice.edu!sun-spots-request From: rana@cs.uwa.oz.au (Ranadeva Peries) Newsgroups: comp.sys.sun Subject: SunCore Problems with SunOS 4.1.1 Keywords: No Digest Subjects in Unmoderated Mode Message-ID: <2943@brchh104.bnr.ca> Date: 4 Jun 91 18:40:00 GMT Sender: news@brchh104.bnr.ca Organization: Sunspots, Psuedo-Unmoderated Lines: 49 Approved: sun-spots@rice.edu X-Original-Date: 8 May 91 04:25:43 GMT Where is usercore.h file under SunOS 4.1.1. Is it /usr/old/usercore.h. Here is a simple C program (from the SunCore Manual). I have modified it to create a new View Surface and draw a glass. This works under SunOS 4.0.3 but does not create a New View Surface under SunOS 4.1.1. User SunOS 4.1.1 it creates the drawing and the view surface on the window it's running. static float glassdx[] = { -10.0, 9.0, 0.0, -14.0, 30.0, -14.0, 0.0, 9.0, -10.0 }; static float glassdy[] = { 0.0, 1.0, 19.0, 15.0, 0.0, -15.0, -19,0, -1.0, 0.0 }; int cgpixwindd(); struct vwsurf vwsurf = DEFAULT_VWSURF(cgpixwindd); main(argc, argv) int argc; char **argv; { struct vwsurf *surf = &vwsurf; initialize_core(BASIC, NOINPUT, TWOD); surf->flags = 1; initialize_view_surface(surf, FALSE); select_view_surface(surf); set_viewport_2(0.125, 0.875, 0.125, 0.75); set_window(-50.0, 50.0, -10.0, 80.0); create_temporary_segment(); move_abs_2(0.0, 0.0); polyline_rel_2(glassdx, glassdy, 9); move_rel_2(-12.0, 33.0); line_rel_2(24.0, 0.0); close_temporary_segment(); sleep(10); deselect_view_surface(surf); terminate_core(); } Rana Peries ( rana@cs.uwa.oz.au ) Department of Computer Science University of Western Australia Nedlands 6009. W Australia.