BRL-CAD

#include <application.h>

Collaboration diagram for application_bundle:
[legend]

Data Fields

uint32_t b_magic
 
struct xrays b_rays
 Actual bundle of rays to be shot. More...
 
struct application b_ap
 application setting to be applied to each ray More...
 
int(* b_hit )(struct application_bundle *, struct partition_bundle *)
 called when bundle hits model More...
 
int(* b_miss )(struct application_bundle *)
 called when entire bundle misses More...
 
int b_user
 application_bundle-specific value More...
 
void * b_uptr
 application_bundle-specific pointer More...
 
int b_return
 

Detailed Description

This structure is the only parameter to rt_shootrays(). The entire structure should be zeroed (e.g. by memset) before it is used the first time.

When calling rt_shootrays(), these fields are mandatory:

 - b_ap  Members in this single ray application structure should
         be set in a similar fashion as when used with
         rt_shootray() with the exception of a_hit() and
         a_miss(). Default implementations of these routines
         are provided that simple update hit/miss counters and
         attach the hit partitions and segments to the
         partition_bundle structure. Users can still override
         this default functionality but have to make sure to
         move the partition and segment list to the new
         partition_bundle structure.
 - b_hit() Routine to call when something is hit by the ray bundle.
 - b_miss() Routine to call when ray bundle misses everything.

Note that rt_shootrays() returns the (int) return of the b_hit()/b_miss() function called, as well as placing it in b_return.

An integer field b_user and a void *field b_uptr are provided in the structure for custom user data.

Definition at line 176 of file application.h.

Field Documentation

◆ b_magic

uint32_t b_magic

Definition at line 178 of file application.h.

◆ b_rays

struct xrays b_rays

Actual bundle of rays to be shot.

Definition at line 180 of file application.h.

◆ b_ap

struct application b_ap

application setting to be applied to each ray

Definition at line 181 of file application.h.

◆ b_hit

int(* b_hit) (struct application_bundle *, struct partition_bundle *)

called when bundle hits model

Definition at line 182 of file application.h.

◆ b_miss

int(* b_miss) (struct application_bundle *)

called when entire bundle misses

Definition at line 183 of file application.h.

◆ b_user

int b_user

application_bundle-specific value

Definition at line 184 of file application.h.

◆ b_uptr

void* b_uptr

application_bundle-specific pointer

Definition at line 185 of file application.h.

◆ b_return

int b_return

Definition at line 186 of file application.h.


The documentation for this struct was generated from the following file: