BRL-CAD
|
#include "common.h"
#include <stdio.h>
#include "vmath.h"
#include "bu/vls.h"
#include "bu/file.h"
#include "rt/defines.h"
#include "rt/mater.h"
#include "rt/db_fullpath.h"
Go to the source code of this file.
Data Structures | |
struct | anim_mat |
struct | rt_anim_property |
struct | rt_anim_color |
struct | animate |
union | animate::animate_specific |
Macros | |
#define | ANM_RSTACK 1 |
Replace stacked matrix. | |
#define | ANM_RARC 2 |
Replace arc matrix. | |
#define | ANM_LMUL 3 |
Left (root side) mul. | |
#define | ANM_RMUL 4 |
Right (leaf side) mul. | |
#define | ANM_RBOTH 5 |
Replace stack, arc=Idn. | |
#define | RT_ANP_REPLACE 1 |
Replace shader string. | |
#define | RT_ANP_APPEND 2 |
Append to shader string. | |
#define | RT_CK_ANP(_p) BU_CKMAG((_p), RT_ANP_MAGIC, "rt_anim_property") |
#define | RT_AN_MATRIX 1 |
Matrix animation. | |
#define | RT_AN_MATERIAL 2 |
Material property anim. | |
#define | RT_AN_COLOR 3 |
Material color anim. | |
#define | RT_AN_SOLID 4 |
Solid parameter anim. | |
#define | RT_AN_TEMPERATURE 5 |
Region temperature. | |
#define | ANIM_NULL ((struct animate *)0) |
#define | RT_CK_ANIMATE(_p) BU_CKMAG((_p), ANIMATE_MAGIC, "animate") |
Functions | |
struct animate * | db_parse_1anim (struct db_i *dbip, int argc, const char **argv) |
int | db_parse_anim (struct db_i *dbip, int argc, const char **argv) |
int | db_add_anim (struct db_i *dbip, struct animate *anp, int root) |
int | db_do_anim (struct animate *anp, mat_t stack, mat_t arc, struct mater_info *materp) |
void | db_free_anim (struct db_i *dbip) |
void | db_write_anim (FILE *fop, struct animate *anp) |
void | db_free_1anim (struct animate *anp) |
void | db_apply_anims (struct db_full_path *pathp, struct directory *dp, mat_t stck, mat_t arc, struct mater_info *materp) |
#define RT_CK_ANP | ( | _p | ) | BU_CKMAG((_p), RT_ANP_MAGIC, "rt_anim_property") |
#define RT_CK_ANIMATE | ( | _p | ) | BU_CKMAG((_p), ANIMATE_MAGIC, "animate") |
Parse one "anim" type command into an "animate" structure.
argv[1] must be the "a/b" path spec, argv[2] indicates what is to be animated on that arc.
A common parser for mged and rt. Experimental. Not the best name for this.
Add a user-supplied animate structure to the end of the chain of such structures hanging from the directory structure of the last node of the path specifier. When 'root' is non-zero, this matrix is located at the root of the tree itself, rather than an arc, and is stored differently.
In the future, might want to check to make sure that callers directory references are in the right database (dbip).
|
extern |
Perform the one animation operation. Leave results in form that additional operations can be cascaded.
Note that 'materp' may be a null pointer, signifying that the region has already been finalized above this point in the tree.
Release chain of animation structures
An unfortunate choice of name.
Writes 'count' bytes into at file offset 'offset' from buffer at 'addr'. A wrapper for the UNIX write() sys-call that takes into account syscall semaphores, stdio-only machines, and in-memory buffering.
Returns - 0 OK -1 FAILURE
|
extern |
'arc' may be a null pointer, signifying an identity matrix. 'materp' may be a null pointer, signifying that the region has already been finalized above this point in the tree.