[<<] [<] Page 1 of 1 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
problems with picture drawing in Nano-X, nxlib and Fltk-UTF8 1.1.6
From: ####@####.#### Date: 20 Jun 2006 13:10:24 +0100 Message-Id: <E1Fsf3i-0006Qz-US@www12.emo.freenet-rz.de> Hello, i have a problem with myself written graphic driver and picture drawing and i think bitblitting to. My self written graphicdriver should be adapted for a special 24 bit VGA (640 x 480)display. The driver is based on thefblin24.c driver whit a mapped memory like a frame buffer. I use Fltk-UTF-8 1.1.6whit nxlib and the Nano-X server. And now my problem: When i don't set thePSF_HAVEBLIT flag, no images where drawn but all other graphicelements like fonts and buttons where drawn correctly. On the other hand, when iset the PSF_HAVEBLIT flag in my graphic driver, the server crashes with the following error: ///------------------------------------------------------- nxclient: bad readblock-1, errno 104 nxclient 755: Corruptedpacket [1]+ Segmentation fault ./nano-X ///------------------------------------------------------- The server crashes onlywhen i use an application whit an picture (bitmap) like button iconore other. Whit an application whiteout pictures the server workscorrectly and draw all things to the display! Is the PSF_HAVEBLIT set,the picture is written correct to the( bit blitting) backgroundmemory at position x,y 0,0 after this the server crashes whit theabove-named error. The struct PSD psd; isfilled by the driver whit the following parameters: psd->xres:640 psd->xvirtres:640 psd->yres:480 psd->yvirtres:480 psd->planes:1 psd->bpp:24 psd->linelen:640 psd->size:921600 psd->ncolors:16777216 psd->pixtype:4 psd->flags:5 psd->addr:(mapped graphic address) psd->portrait:0 psd->attr:0 psd->flags= PSF_SCREEN | PSF_HAVEBLIT; psd->portrait= MWPORTRAIT_NONE; psd->pixtype= MWPF_TRUECOLOR888 and pointers to thedrawing functions like DrawPixel, DrawHLine, Blit(), .... are alsoset. My opinion is that somePSD parameters are seated wrong from me. Is the psd->linelen =640 to large? Can any body help me ? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] problems with picture drawing in Nano-X, nxlib and Fltk-UTF8 1.1.6
From: "Greg Haerr" ####@####.#### Date: 21 Jun 2006 05:05:42 +0100 Message-Id: <062f01c694e7$f230d2c0$6401a8c0@winXP> psd->linelen:640 This value probably needs to be 640*3, since linelen is supposed to be the number of bytes, not pixels. Later, due to complicated reasons, the linear24_init() routine changes this back to 640. Regards, Greg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] problems with picture drawing in Nano-X, nxlib and Fltk-UTF8 1.1.6
From: Andi ####@####.#### Date: 27 Jun 2006 19:39:54 +0100 Message-Id: <2006626224549.526450@datapop> Hello Greg, yes the psd->linelen was the problem! The psd->linelen is being changed in the sub driver drawing functions, therefore crashes my memory address calculating. Thanks It works now. Best regards On Tue, 20 Jun 2006 22:05:15 -0600, Greg Haerr wrote: > psd->linelen:640 > > > This value probably needs to be 640*3, since > linelen is supposed to be the number of bytes, > not pixels. Later, due to complicated reasons, > the linear24_init() routine changes this back > to 640. > > > Regards, > > > Greg > > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 1 [>] [>>] |