From: Frank Bennett Subject: go32-1.09 2 problems (fwd) To: djgpp AT sun DOT soe DOT clarkson DOT edu Date: Fri, 18 Dec 92 10:01:24 MST Mailer: Elm [revision: 66.25] Go32, Debug32 version 1.00 has been working great for me. I resently picked up version 1.09 and now a couple things don't work: 1) go32 now_existant_dos_short_file_name cause my machine to reboot. I am able to make go32/debug32 under 1.09. I also was able to step through go32 using Borland td all the way up to paging.c where things seem to blowup on the exit(1) when it can't open the file. I am using turbo C ver 2.0. any suggestions? 2) I added a GrHiColor mode to libgr - code below - similar to setmode.s But the graphics display seems to stay in regular old VGA mode. In looking at go32/graphics.c, exphdlr.c I don't see how my hack ever worked, i_10 is looking for 0xffxx in eax? However if I link in dgraphics.obj - which loads the driver sooner than later - it works! thank in advance for any suggestions, Frank environment, setup under mks shell running under DRDOS 5.0 on a AMD 386DX-40, hence / not \: That is except for GO32. LIBRARY_PATH=c:/c/djgpp/lib PROMPT=$P$G OS=DRDOS ROOTDIR=c:/mks BISON_SIMPLE=c:/c/djgpp/lib/bison.simple GCCLIB=c:/c/djgpp/lib GCCBIN=c:cdjgppbin COMPILER_PATH=c:/c/djgpp/bin GCCINC=c:/c/djgpp/include GRXFONT=c:/djgpp/contrib/libgrx/fonts HOME=c:/mks COMSPEC=c:/command.com GO32TMP=c:/tmp OBJC_INCLUDE_PATH=c:/c/djgpp/include VER=5.0 PATH=.;c:/c/djgpp/bin;c:/mks/bin;c:/windows;c:/bin;c:/tc;c:/drdos TZ=EST0EDT TMPDIR=c:/tmp OBJCPLUS_INCLUDE_PATH=c:/c/djgpp/include C_INCLUDE_PATH=c:/c/djgpp/include;c:/c/djgpp/contrib/include FLEX_SKELETON=c:/c/djgpp/lib/flex.skeleton CPLUS_INCLUDE_PATH=c:/c/djgpp/cplusinc;c:/c/djgpp/include BISON_HAIRY=c:/c/djgpp/lib/bison.hairy SHELL=c:/mks/bin/sh.exe GO32=ansi driver c:\c\djgpp\drivers\tseng4k.grd gw 800 gh 600 GCCTMP=c:/tmp _=c:/mks/bin/env.exe /* This is file hicolor.s setup hicolor serria mode, that is 16 bit pixels 5:5:5, but... notcompatible with GrPlot, mouse, colortable setup, etc .. all assume 8 bit pixels */ .data .globl __GrCurMode .comm __GrCurMode,4 .globl __GrSetModeHook .comm __GrSetModeHook,4 .text .globl _GrHiColor _GrHiColor: push %ebp movl %esp,%ebp pushl %ebx movl $0x2e,%eax movl %eax,__GrCurMode movl $0x10f0,%eax movb $0x2e,%bl int $0x10 movl $640,%ecx movl $480,%edx movl %ecx,__GrSizeX movl %edx,__GrSizeY decl %ecx decl %edx movl %ecx,__GrMaxX movl %edx,__GrMaxY movl %ebx,__GrCanBcopyInBlit popl %ebx popl %ebp ret the following pokes color values into the VGA framebuffer in high color mode: hicolor(x, y, r,g,b) int x,y; unsigned char r,g,b; { unsigned short *p, pix; p = (unsigned short *)0xd0000000 + 640*y + x; *p = ((r&0xf8)<<7)|((g&0xf8)<<2)|(b>>3); /* pix = ((r&0xf8)<<7)|((g&0xf8)<<2)|(b>>3); GrPlot( y, x, pix); */ }