[futurebasic] Re: [FB] [FB^3] Bus Error on SETGWORLD

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : September 1999 : Group Archive : Group : All Groups

From: "Michael Evans" <mikonic@...>
Date: Sun, 26 Sep 1999 10:58:47 -0400
> When running this code , I get a bus error on the line CALL SETGWORLD
> 
> clear local mode
> dim theRect;8 , offPort& , QDErr
> local fn MyNewGWorld(rectPtr&)
>   blockmove rectPtr&,@theRect,8
>   QDErr = FN NEWGWORLD(offPort&,0,theRect,0,0,0)'offPort contains offScreen
> port
>   LONG IF QDErr                                                        'check
> for error
>     LONG IF offPort&
>       CALL DISPOSEGWORLD(offPort&)                        'dump GWORLD block
> if necessary
>       offPort&=0
>     END IF
>   XELSE
>    CALL SETGWORLD(offPort&,0) '<-------------bus error
>   END IF
> END FN=offPort&
>
> Any one knows why ?
>
> Pierre

Pierre:

I think you are failing because of illegal bit depth in the gWorld you're
trying to set.

Examine FN RdWrSetWorld in the RdWrUtilities.FLTR sold by Staz Software to
see how its done properly.

I believe that RdWrUtilities.FLTR is sold seperately from FBII but is
bundled with FB^3


Cheers,


----------------------------------------------------------
Michael Evans
Manager of Software Development * Photo Systems, Inc.
3301 Wood Valley Road, NW * Atlanta, GA, 30327-1515
Voice: (404) 846-9386
Fax: (404) 240-0878 * Cell: (404) 229-3930
E-mail: evans@... * michael_evans@...
----------------------------------------------------------