On 8/26/08, Christopher Sean Morrison <[EMAIL PROTECTED]> wrote: > > >If I have a 'struct rt_comb_internal' pointer (say, combp): > > > > 1. How do I confirm it's a region? > > > > I believe I test combp->region_flag for truth. If it is true, > >does that guarantee any regions below it are not acting as regions?
But at least that should be the "top-level" or parent region (the first from the top) on that path, though, right (using db_tree_walk)? > > 2. If it's possible, how do I manipulate combp to get to its region pointer? > > Presuming you mean get a "struct region"? Those are stored in a ray trace > instance (rtip) so you'll have to have some portion of the model loaded and > prepared for ray-tracing (even if you don't shoot a ray). With the rtip and > the name of the region, you can call rt_getregion(rtip, name) to get a struct > region for that region. There are a variety of other ways as well, just > depends what you're trying to do and what you already have. See answer to Lee's reply for how I got the combp. Any way to get the struct region from there? Thanks, Sean. -Tom > p.s. For future reference, coding questions like this should really be sent > to brlcad-devel instead of brlcad-users. Will do. ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ BRL-CAD Developer mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/brlcad-devel
