![]() |
Bsoft 2.1.4
Bernard's software package
|
Library routines used for model transformation. More...
Functions | |
long | model_center (Bmodel *model) |
Shifts one models to its center of mass. More... | |
long | model_shift (Bmodel *model, Vector3< double > shift) |
Shifts a model. More... | |
long | models_shift (Bmodel *model, Vector3< double > shift) |
Shifts all models. More... | |
long | models_trim (Bmodel *model, Vector3< double > trim) |
Trims models to a new enclosing box size. More... | |
long | model_scale (Bmodel *model, Vector3< double > scale, Vector3< double > origin) |
Scales a model. More... | |
long | models_scale (Bmodel *model, Vector3< double > scale, Vector3< double > origin) |
Scales a model. More... | |
long | model_reflect (Bmodel *model, Vector3< double > normal, Vector3< double > origin) |
Reflects the model through a mirror plane. More... | |
long | models_reflect (Bmodel *model, Vector3< double > normal, Vector3< double > origin) |
Reflects the model through a mirror plane. More... | |
double | model_reflect_and_compare (Bmodel *model, Vector3< double > normal, Vector3< double > origin) |
Copies and reflects the model and compares it with the original. More... | |
long | model_rotate (Bmodel *model, Matrix3 mat, Vector3< double > origin, Vector3< double > shift) |
Rotates the model. More... | |
long | models_rotate (Bmodel *model, Matrix3 mat, Vector3< double > origin, Vector3< double > shift) |
Rotates the models. More... | |
long | model_rotate (Bmodel *model, Matrix3 mat) |
Rotates the model. More... | |
long | models_rotate (Bmodel *model, Matrix3 mat) |
Rotates the models. More... | |
long | model_rotate (Bmodel *model, Matrix3 mat, Vector3< double > origin) |
Rotates the model. More... | |
long | models_rotate (Bmodel *model, Matrix3 mat, Vector3< double > origin) |
Rotates the models. More... | |
long | model_rotate (Bmodel *model, View2< float > view) |
Rotates the model. More... | |
long | models_rotate (Bmodel *model, View2< float > view) |
Rotates the models. More... | |
long | model_rotate (Bmodel *model, View2< float > view, Vector3< double > origin, Vector3< double > shift) |
Rotates the model. More... | |
long | models_rotate (Bmodel *model, View2< float > view, Vector3< double > origin, Vector3< double > shift) |
Rotates the models. More... | |
long | model_rotate (Bmodel *model, Transform t) |
Rotates the model. More... | |
long | models_rotate (Bmodel *model, Transform t) |
Rotates the models. More... | |
double | model_rotate_and_compare (Bmodel *model, Transform t) |
Copies and rotates the model and compares it with the original. More... | |
long | model_adjust_for_binning (Bmodel *model, Vector3< long > bin) |
A binned model list is converted back to the unbinned version. More... | |
long | model_align_to_guide (Bmodel *model, Bmodel *guide) |
A model is oriented to coincide with a guide model. More... | |
Transform | model_find_transform (Bmodel *model, Bmodel *refmod) |
A model is fitted to a reference model. More... | |
int | model_random_displace_number (Bmodel *model, long number, double stdev) |
Applies random displacements to a selected number of coordinates. More... | |
Library routines used for model transformation.
A binned model list is converted back to the unbinned version.
*model | the model list. |
bin | 3-value bin vector. |
All component coordinates are converted back to the unbinned values. Only the first model is adjusted.
A model is oriented to coincide with a guide model.
*model | model (rotated). |
*guide | guide model. |
The principal axes of the guide model is calculated and the model rotated. Only the first model is aligned.
long model_center | ( | Bmodel * | model | ) |
Shifts one models to its center of mass.
*model | model parameters. |
Only the first model in the list is processed.
A model is fitted to a reference model.
*model | model. |
*refmod | template model. |
The components in the model and the reference must match exactly. Only the first model and template in the lists are processed.
int model_random_displace_number | ( | Bmodel * | model, |
long | number, | ||
double | stdev | ||
) |
Applies random displacements to a selected number of coordinates.
*model | model to be modified. |
number | number of coordinates to displace. |
stdev | standard deviation of displacement. |
Reflects the model through a mirror plane.
*model | model structure. |
normal | plane normal. |
origin | model origin. |
Only the first model in the list is processed.
double model_reflect_and_compare | ( | Bmodel * | model, |
Vector3< double > | normal, | ||
Vector3< double > | origin | ||
) |
Copies and reflects the model and compares it with the original.
*model | model structure. |
normal | plane normal. |
origin | model origin. |
Only the first model in the list is processed.
Rotates the model.
*model | model structure. |
mat | rotation matrix. |
Only the first model in the list is processed.
Rotates the model.
*model | model structure. |
mat | rotation matrix. |
origin | rotation origin. |
Only the first model in the list is processed.
long model_rotate | ( | Bmodel * | model, |
Matrix3 | mat, | ||
Vector3< double > | origin, | ||
Vector3< double > | shift | ||
) |
Rotates the model.
*model | model structure. |
mat | rotation matrix. |
origin | rotation origin. |
shift | translation after rotation. |
Only the first model in the list is processed.
Rotates the model.
*model | model structure. |
t | rotation operation. |
Only the first model in the list is processed.
Rotates the model.
*model | model structure. |
view | view to rotate to. |
Only the first model in the list is processed.
long model_rotate | ( | Bmodel * | model, |
View2< float > | view, | ||
Vector3< double > | origin, | ||
Vector3< double > | shift | ||
) |
Rotates the model.
*model | model structure. |
view | view to rotate to. |
origin | rotation origin. |
shift | translation after rotation. |
Only the first model in the list is processed.
Copies and rotates the model and compares it with the original.
*model | model structure. |
t | rotation operation. |
Only the first model in the list is processed.
Scales a model.
*model | model parameters. |
scale | scale. |
origin | model origin. |
Only the first model in the list is processed.
Shifts a model.
*model | model parameters. |
shift | translation vector. |
Only the first model in the list is processed.
Reflects the model through a mirror plane.
*model | model structure. |
normal | plane normal. |
origin | model origin. |
Rotates the models.
*model | model structure. |
mat | rotation matrix. |
Rotates the models.
*model | model structure. |
mat | rotation matrix. |
origin | rotation origin. |
long models_rotate | ( | Bmodel * | model, |
Matrix3 | mat, | ||
Vector3< double > | origin, | ||
Vector3< double > | shift | ||
) |
Rotates the models.
*model | model structure. |
mat | rotation matrix. |
origin | rotation origin. |
shift | translation after rotation. |
Rotates the models.
*model | model structure. |
t | rotation operation. |
Only the first model in the list is processed.
Rotates the models.
*model | model structure. |
view | view to rotate to. |
long models_rotate | ( | Bmodel * | model, |
View2< float > | view, | ||
Vector3< double > | origin, | ||
Vector3< double > | shift | ||
) |
Rotates the models.
*model | model structure. |
view | view to rotate to. |
origin | rotation origin. |
shift | translation after rotation. |
Scales a model.
*model | model parameters. |
scale | scale. |
origin | model origin. |
Shifts all models.
*model | model parameters. |
shift | translation vector. |
All models in the list are processed.