Article View: comp.sys.sgi.graphics
Article #183Re: Help to transplate a software of Ocatne,Indigo2 to O2 on Irix 6.5
From: nagata s
Date: Wed, 22 Nov 2000 07:15
Date: Wed, 22 Nov 2000 07:15
52 lines
3137 bytes
3137 bytes
Here is my program using stencil() runing on Indigo2,Ocatne, but not on O2.
Appreciate very much Any suggestions to fix it.
----from here
void stencilmask(int eyer){
if(eyer==0) stencil(TRUE,0x1, SF_EQUAL, 0x1, ST_KEEP, ST_KEEP,
ST_KEEP);
else if(eyer==1) stencil(TRUE,0x1, SF_NOTEQUAL,0x1, ST_KEEP, ST_KEEP,
ST_KEEP);
}
void
cilpatdraw(){
static int gid2, j;
static long vert1[2],vert2[2];
static long xscrmax,yscrmax;
prefposition(0.0, xscrmax, 0.0, yscrmax);
gid2= winopen(" stencil pattern");
ortho2( 0.0, xscrmax, 0.0, yscrmax);
stensize(1); sclear(0x00); subpixel(1);
stencil(TRUE, 1, SF_ALWAYS, 0x1, ST_REPLACE, ST_REPLACE, ST_REPLACE);
zfunction(ZF_NEVER); cpack(0x00); clear();
vert1[0]= 0.0; vert2[0]= xscrmax;
for(j= 0; j<yscrmax; j+=2){
vert1[1]= vert2[1]= j;
bgnline(); v2i(vert1); v2i(vert2); endline();
}
winclose(gid2);
}/* end*/
David P. Gorgen <dgorgen@annarbor.engr.sgi.com> wrote in message news:8v3snp$bfu3$1@fido.engr.sgi.com...
> nospam@oddhack.engr.sgi.com (Jon Leech) writes:
> > - Have you checked for any OpenGL errors generated during execution of
> > the program?
>
> Helpful hint: a really easy way to do this on SGI's is to
>
> > setenv GLERRORABORT anything
>
> (or the equivalent way to set an environment varible in non-csh
> shells).
>
> Then any time a GL error occurs, your program will abort(), and you can
> use a debugger to get a stack trace.
>
> Note, it is a terrible idea to use this in a production environment!
> But as a diagnostic tool it's great.
> --
> David Gorgen Principal Engineer Silicon Graphics, Inc.
> dgorgen 'at' sgi.com 1600 Amphitheatre Pkwy. MS 43-2-991
> Voice:650-933-3493 Fax:650-932-3493 Mountain View, CA 94043-1351
Technical Details
Message-ID:
<8vfrjo$cbv$1@strlnews.strl.nhk.or.jp>Path:
arc1-ca.pugleaf.net!supernews.google.com!sn-xit-02!supernews.com!isdnet!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.mesh.ad.jp!giga-nspixp2!np0.iij.ad.jp!news.iij.ad.jp!news.strl.nhk.or.jp!not-for-mailReferences:
<8v27vn$2ge$1@strlnews.strl.nhk.or.jp> <8v28al$2m4$1@strlnews.strl.nhk.or.jp> <8v2adh$3t8o$1@fido.engr.sgi.com> <8v3snp$bfu3$1@fido.engr.sgi.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10268b,8bb5b8eec0c39f1a X-Google-Attributes: gid10268b,public X-Google-Thread: fc443,8bb5b8eec0c39f1a X-Google-Attributes: gidfc443,public X-Google-ArrivalTime: 2000-11-21 23:18:40 PST Path: arc1-ca.pugleaf.net!supernews.google.com!sn-xit-02!supernews.com!isdnet!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.mesh.ad.jp!giga-nspixp2!np0.iij.ad.jp!news.iij.ad.jp!news.strl.nhk.or.jp!not-for-mail From: "nagata s" <nagata@strl.nhk.or.jp> Newsgroups: comp.sys.sgi.graphics,fj.sys.sgi Subject: Re: Help to transplate a software of Ocatne,Indigo2 to O2 on Irix 6.5 Date: Wed, 22 Nov 2000 16:15:35 +0900 Organization: NHK Science and Technical Research Laboratories, Tokyo, Japan. Lines: 54 Message-ID: <8vfrjo$cbv$1@strlnews.strl.nhk.or.jp> References: <8v27vn$2ge$1@strlnews.strl.nhk.or.jp> <8v28al$2m4$1@strlnews.strl.nhk.or.jp> <8v2adh$3t8o$1@fido.engr.sgi.com> <8v3snp$bfu3$1@fido.engr.sgi.com> NNTP-Posting-Host: hdhcp8.strl.nhk.or.jp Mime-Version: 1.0 Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2314.1300 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300