Back to index

radiance  4R0+20100331
Typedefs | Functions | Variables
rtotypes.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef int otype_tracef (OBJREC *o, RAY *r)

Functions

void freetext (OBJREC *m)

Variables

otype_tracef o_sphere
otype_tracef o_face
otype_tracef o_cone
otype_tracef o_instance
otype_tracef o_mesh
otype_tracef m_aniso
otype_tracef m_dielectric
otype_tracef m_glass
otype_tracef m_alias
otype_tracef m_light
otype_tracef m_normal
otype_tracef m_mist
otype_tracef m_mirror
otype_tracef m_direct
otype_tracef m_clip
otype_tracef m_brdf
otype_tracef m_brdf2
otype_tracef t_func
otype_tracef t_data
otype_tracef p_cfunc
otype_tracef p_bfunc
otype_tracef p_pdata
otype_tracef p_cdata
otype_tracef p_bdata
otype_tracef mx_func
otype_tracef mx_data
otype_tracef mx_pdata
otype_tracef do_text

Typedef Documentation

typedef int otype_tracef(OBJREC *o, RAY *r)

Definition at line 6 of file rtotypes.h.


Function Documentation

void freetext ( OBJREC m)

Definition at line 249 of file text.c.

{
       register TEXT  *tp;
       register TLINE  *tlp;

       tp = (TEXT *)m->os;
       if (tp == NULL)
              return;
       while ((tlp = tp->tl.next) != NULL) {
              tp->tl.next = tlp->next;
              free((void *)tlp->spc);
              free((void *)tlp);
       }
       freefont(tp->f);     /* release font reference */
       free((void *)tp);
       m->os = NULL;
}

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

int o_face

Definition at line 484 of file rad2mgf.c.

{
       char   entbuf[2048], *linestart;
       register char *cp;
       register int  i;

       if ((fa->nfargs < 9) | (fa->nfargs % 3))
              return(-1);
       setmat(mod);
       setobj(id);
       cp = linestart = entbuf;
       *cp++ = 'f';
       for (i = 0; i < fa->nfargs; i += 3) {
              *cp++ = ' ';
              if (cp - linestart > 72) {
                     *cp++ = '\\'; *cp++ = '\n';
                     linestart = cp;
                     *cp++ = ' '; *cp++ = ' ';
              }
              getvertid(cp, fa->farg + i);
              while (*cp)
                     cp++;
       }
       puts(entbuf);
       return(0);
}

Definition at line 612 of file rad2mgf.c.

{
       register int  i;
       register char *cp;
       char   *start = NULL, *end = NULL;
       /*
        * We don't really know how to do this, so we just create
        * a reference to an undefined MGF file and it's the user's
        * responsibility to create this file and put the appropriate
        * stuff into it.
        */
       if (fa->nsargs < 1)
              return(-1);
       setmat(mod);                /* only works if surfaces are void */
       setobj(id);
       for (cp = fa->sarg[0]; *cp; cp++)  /* construct MGF file name */
              if (*cp == '/')
                     start = cp+1;
              else if (*cp == '.')
                     end = cp;
       if (start == NULL)
              start = fa->sarg[0];
       if (end == NULL || start >= end)
              end = cp;
       fputs("i ", stdout);               /* print include entity */
       for (cp = start; cp < end; cp++)
              putchar(*cp);
       fputs(".mgf", stdout);                    /* add MGF suffix */
       for (i = 1; i < fa->nsargs; i++) { /* add transform */
              putchar(' ');
              fputs(fa->sarg[i], stdout);
       }
       putchar('\n');
       clrverts();                 /* vertex id's no longer reliable */
       return(0);
}