- replaced AUTOSPACE define with {ME_,CU_,MB_}AUTOSPACE,
different objects shouldn't share flags this way (still sharing of other mesh flags in renderer... ickity pickity, but I'm not fixing now) - removed some unnecessary uses of DNA_mesh_types.h
This commit is contained in:
@@ -53,7 +53,6 @@
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_curve_types.h"
|
||||
#include "DNA_material_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
|
||||
/* for dereferencing pointers */
|
||||
#include "DNA_ID.h"
|
||||
@@ -171,7 +170,7 @@ Curve *add_curve(int type)
|
||||
cu->width= 1.0;
|
||||
cu->spacing= cu->linedist= 1.0;
|
||||
cu->fsize= 1.0;
|
||||
cu->texflag= AUTOSPACE;
|
||||
cu->texflag= CU_AUTOSPACE;
|
||||
|
||||
cu->bb= unit_boundbox();
|
||||
|
||||
@@ -339,7 +338,7 @@ void tex_space_curve(Curve *cu)
|
||||
bb->vec[0][2]=bb->vec[3][2]=bb->vec[4][2]=bb->vec[7][2]= loc[2]-size[2];
|
||||
bb->vec[1][2]=bb->vec[2][2]=bb->vec[5][2]=bb->vec[6][2]= loc[2]+size[2];
|
||||
|
||||
if(cu->texflag & AUTOSPACE) {
|
||||
if(cu->texflag & CU_AUTOSPACE) {
|
||||
VECCOPY(cu->loc, loc);
|
||||
VECCOPY(cu->size, size);
|
||||
cu->rot[0]= cu->rot[1]= cu->rot[2]= 0.0;
|
||||
|
||||
@@ -48,7 +48,6 @@
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_meta_types.h"
|
||||
#include "DNA_scene_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
|
||||
|
||||
#include "BLI_blenlib.h"
|
||||
@@ -104,7 +103,7 @@ MetaBall *add_mball()
|
||||
mb= alloc_libblock(&G.main->mball, ID_MB, "Meta");
|
||||
|
||||
mb->size[0]= mb->size[1]= mb->size[2]= 1.0;
|
||||
mb->texflag= AUTOSPACE;
|
||||
mb->texflag= MB_AUTOSPACE;
|
||||
|
||||
mb->wiresize= 0.4f;
|
||||
mb->rendersize= 0.2f;
|
||||
|
||||
@@ -216,7 +216,7 @@ Mesh *add_mesh()
|
||||
|
||||
me->size[0]= me->size[1]= me->size[2]= 1.0;
|
||||
me->smoothresh= 30;
|
||||
me->texflag= AUTOSPACE;
|
||||
me->texflag= ME_AUTOSPACE;
|
||||
me->flag= ME_TWOSIDED;
|
||||
me->subdiv= 1;
|
||||
me->subdivr = 1;
|
||||
@@ -397,7 +397,7 @@ void tex_space_mesh(Mesh *me)
|
||||
|
||||
boundbox_mesh(me, loc, size);
|
||||
|
||||
if(me->texflag & AUTOSPACE) {
|
||||
if(me->texflag & ME_AUTOSPACE) {
|
||||
if(me->key) {
|
||||
kb= me->key->refkey;
|
||||
if (kb) {
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
#include "DNA_ika_types.h"
|
||||
#include "DNA_lamp_types.h"
|
||||
#include "DNA_material_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
#include "DNA_group_types.h"
|
||||
#include "DNA_curve_types.h"
|
||||
#include "DNA_userdef_types.h"
|
||||
|
||||
@@ -57,7 +57,6 @@
|
||||
|
||||
#include "DNA_texture_types.h"
|
||||
#include "DNA_key_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_lamp_types.h"
|
||||
#include "DNA_material_types.h"
|
||||
|
||||
@@ -162,6 +162,9 @@ typedef struct IpoCurve {
|
||||
|
||||
/* **************** CURVE ********************* */
|
||||
|
||||
/* texflag */
|
||||
#define CU_AUTOSPACE 1
|
||||
|
||||
/* flag */
|
||||
#define CU_3D 1
|
||||
#define CU_FRONT 2
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
/**
|
||||
* blenlib/DNA_mesh_types.h (mar-2001 nzc)
|
||||
*
|
||||
* Mesh stuff.
|
||||
*
|
||||
* $Id$
|
||||
*
|
||||
* ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
/**
|
||||
* blenlib/DNA_mesh_types.h (mar-2001 nzc)
|
||||
*
|
||||
* Mesh stuff.
|
||||
*
|
||||
* $Id$
|
||||
*
|
||||
* ***** BEGIN GPL/BL DUAL LICENSE BLOCK *****
|
||||
@@ -154,7 +150,7 @@ typedef struct Mesh {
|
||||
/* **************** MESH ********************* */
|
||||
|
||||
/* texflag */
|
||||
#define AUTOSPACE 1
|
||||
#define ME_AUTOSPACE 1
|
||||
|
||||
/* me->flag */
|
||||
#define ME_ISDONE 1
|
||||
|
||||
@@ -82,6 +82,9 @@ typedef struct MetaBall {
|
||||
|
||||
#define MB_MAXELEM 1024
|
||||
|
||||
/* texflag */
|
||||
#define MB_AUTOSPACE 1
|
||||
|
||||
/* mb->flag */
|
||||
#define MB_UPDATE_ALWAYS 0
|
||||
#define MB_UPDATE_HALFRES 1
|
||||
|
||||
@@ -46,7 +46,6 @@
|
||||
|
||||
#include "DNA_camera_types.h"
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
#include "DNA_image_types.h"
|
||||
#include "DNA_texture_types.h"
|
||||
#include "DNA_lamp_types.h"
|
||||
|
||||
@@ -37,7 +37,6 @@
|
||||
|
||||
#include "DNA_material_types.h"
|
||||
#include "DNA_lamp_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
|
||||
#include "BKE_utildefines.h"
|
||||
|
||||
|
||||
@@ -63,7 +63,6 @@
|
||||
#include "DNA_sound_types.h"
|
||||
#include "DNA_text_types.h"
|
||||
#include "DNA_view3d_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
|
||||
#include "BKE_library.h"
|
||||
#include "BKE_global.h"
|
||||
|
||||
@@ -58,7 +58,6 @@
|
||||
#include "DNA_lattice_types.h"
|
||||
#include "DNA_material_types.h"
|
||||
#include "DNA_meta_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_radio_types.h"
|
||||
#include "DNA_screen_types.h"
|
||||
|
||||
@@ -60,7 +60,6 @@
|
||||
#include "DNA_scene_types.h"
|
||||
#include "DNA_space_types.h"
|
||||
#include "DNA_constraint_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
#include "DNA_key_types.h"
|
||||
|
||||
#include "BKE_action.h"
|
||||
|
||||
@@ -48,7 +48,6 @@
|
||||
#include "BLI_arithb.h"
|
||||
|
||||
#include "DNA_ID.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_oops_types.h"
|
||||
#include "DNA_scene_types.h"
|
||||
|
||||
@@ -3228,21 +3228,21 @@ void ob_to_tex_transob(Object *ob, TransOb *tob)
|
||||
if(id==0);
|
||||
else if( GS(id->name)==ID_ME) {
|
||||
me= ob->data;
|
||||
me->texflag &= ~AUTOSPACE;
|
||||
me->texflag &= ~ME_AUTOSPACE;
|
||||
tob->loc= me->loc;
|
||||
tob->rot= me->rot;
|
||||
tob->size= me->size;
|
||||
}
|
||||
else if( GS(id->name)==ID_CU) {
|
||||
cu= ob->data;
|
||||
cu->texflag &= ~AUTOSPACE;
|
||||
cu->texflag &= ~CU_AUTOSPACE;
|
||||
tob->loc= cu->loc;
|
||||
tob->rot= cu->rot;
|
||||
tob->size= cu->size;
|
||||
}
|
||||
else if( GS(id->name)==ID_MB) {
|
||||
mb= ob->data;
|
||||
mb->texflag &= ~AUTOSPACE;
|
||||
mb->texflag &= ~MB_AUTOSPACE;
|
||||
tob->loc= mb->loc;
|
||||
tob->rot= mb->rot;
|
||||
tob->size= mb->size;
|
||||
|
||||
@@ -65,7 +65,6 @@
|
||||
#include "DNA_object_types.h"
|
||||
#include "DNA_space_types.h"
|
||||
#include "DNA_userdef_types.h"
|
||||
#include "DNA_mesh_types.h"
|
||||
|
||||
#include "BKE_blender.h"
|
||||
#include "BKE_curve.h"
|
||||
|
||||
Reference in New Issue
Block a user