Re: global vars and sharedArena vars

New Message Reply Date view Thread view Subject view Author view

Angus Dorbie (dorbie++at++bitch.reading.sgi.com)
Fri, 29 Nov 1996 17:08:30 +0000


Changing the value of a global variable in one process won't affect
it's value in another after you've called pfConfig (which is when you
go multithreaded), so you have to use shared memory.

On Nov 29, 4:45pm, Peter Schulze wrote:
> Subject: global vars and sharedArena vars
> Hi,
> I'd like to ask, where is the difference between vars in "shared Arena"
> and global vars. By default I put all my vars handeled by different
> processes(isect,app,cull,draw) into the shared arena, but I think it
> "looks" better to init them as global (and I don't have to write long
> pointer names).
> Wouldn't a function (for example) located in the isect-process, changing
> some widgets of the panel and some parameters off the draw-process work
> as good by using global variables, although these actions should be
> enabled in the next frame ?
> Isn't a global var as visible to all processes as a shared var located
> in shared arena ?

No, it'll share the value at the time of the call to pfConfig but after
that it has separate location in physical memory for each process.

> Peter

>-- End of excerpt from Peter Schulze

Cheers,
Angus.

=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
            Submissions: info-performer++at++sgi.com
        Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:54:02 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.