replace u_int64_t with cc99's uint64_t as suggested by Nicholas Bishop.

This commit is contained in:
Campbell Barton 2011-12-24 03:03:42 +00:00
parent 33bd38ebc7
commit eb3beca8d4
15 changed files with 37 additions and 22 deletions

View File

@ -93,6 +93,14 @@ typedef unsigned long uintptr_t;
/* Linux-i386, Linux-Alpha, Linux-ppc */
#include <stdint.h>
/* XXX */
#ifndef uint64_t
typedef uint8_t u_int8_t;
typedef uint16_t u_int16_t;
typedef uint32_t u_int32_t;
typedef uint64_t u_int64_t;
#endif
#elif defined (__APPLE__)
#include <inttypes.h>

View File

@ -41,7 +41,7 @@ extern "C" {
struct ID;
struct CustomData;
struct CustomDataLayer;
typedef u_int64_t CustomDataMask;
typedef uint64_t CustomDataMask;
extern const CustomDataMask CD_MASK_BAREMESH;
extern const CustomDataMask CD_MASK_MESH;

View File

@ -69,7 +69,7 @@ typedef struct DagNode
int ancestor_count;
unsigned int lay; // accumulated layers of its relations + itself
unsigned int scelay; // layers due to being in scene
u_int64_t customdata_mask; // customdata mask
uint64_t customdata_mask; // customdata mask
int lasttime; // if lasttime != DagForest->time, this node was not evaluated yet for flushing
int BFS_dist; // BFS distance
int DFS_dist; // DFS distance

View File

@ -2563,7 +2563,7 @@ void object_handle_update(Scene *scene, Object *ob)
#else /* ensure CD_MASK_BAREMESH for now */
EditMesh *em = (ob == scene->obedit)? BKE_mesh_get_editmesh(ob->data): NULL;
u_int64_t data_mask= scene->customdata_mask | ob->customdata_mask | CD_MASK_BAREMESH;
uint64_t data_mask= scene->customdata_mask | ob->customdata_mask | CD_MASK_BAREMESH;
if(em) {
makeDerivedMesh(scene, ob, em, data_mask); /* was CD_MASK_BAREMESH */
BKE_mesh_end_editmesh(ob->data, em);

View File

@ -86,6 +86,14 @@ typedef unsigned long uintptr_t;
/* Linux-i386, Linux-Alpha, Linux-ppc */
#include <stdint.h>
/* XXX */
#ifndef uint64_t
typedef uint8_t u_int8_t;
typedef uint16_t u_int16_t;
typedef uint32_t u_int32_t;
typedef uint64_t u_int64_t;
#endif
#elif defined (__APPLE__)
#include <inttypes.h>

View File

@ -286,8 +286,8 @@ Base *ED_view3d_give_base_under_cursor(struct bContext *C, const int mval[2]);
void ED_view3d_quadview_update(struct ScrArea *sa, struct ARegion *ar, short do_clip);
int ED_view3d_lock(struct RegionView3D *rv3d);
u_int64_t ED_view3d_datamask(struct Scene *scene, struct View3D *v3d);
u_int64_t ED_viewedit_datamask(struct bScreen *screen);
uint64_t ED_view3d_datamask(struct Scene *scene, struct View3D *v3d);
uint64_t ED_viewedit_datamask(struct bScreen *screen);
/* camera lock functions */
int ED_view3d_camera_lock_check(struct View3D *v3d, struct RegionView3D *rv3d);

View File

@ -250,8 +250,8 @@ typedef struct Object {
struct FluidsimSettings *fluidsimSettings; /* if fluidsim enabled, store additional settings */
struct DerivedMesh *derivedDeform, *derivedFinal;
u_int64_t lastDataMask; /* the custom data layer mask that was last used to calculate derivedDeform and derivedFinal */
u_int64_t customdata_mask; /* (extra) custom data layer mask to use for creating derivedmesh, set by depsgraph */
uint64_t lastDataMask; /* the custom data layer mask that was last used to calculate derivedDeform and derivedFinal */
uint64_t customdata_mask; /* (extra) custom data layer mask to use for creating derivedmesh, set by depsgraph */
unsigned int state; /* bit masks of game controllers that are active */
unsigned int init_state; /* bit masks of initial state as recorded by the users */

View File

@ -970,8 +970,8 @@ typedef struct Scene {
/* Movie Tracking */
struct MovieClip *clip; /* active movie clip */
u_int64_t customdata_mask; /* XXX. runtime flag for drawing, actually belongs in the window, only used by object_handle_update() */
u_int64_t customdata_mask_modal; /* XXX. same as above but for temp operator use (gl renders) */
uint64_t customdata_mask; /* XXX. runtime flag for drawing, actually belongs in the window, only used by object_handle_update() */
uint64_t customdata_mask_modal; /* XXX. same as above but for temp operator use (gl renders) */
} Scene;

View File

@ -667,7 +667,7 @@ static eSDNA_Type sdna_type_nr(const char *dna_type)
else if( strcmp(dna_type, "float")==0) return SDNA_TYPE_FLOAT;
else if( strcmp(dna_type, "double")==0) return SDNA_TYPE_DOUBLE;
else if( strcmp(dna_type, "int64_t")==0) return SDNA_TYPE_INT64;
else if( strcmp(dna_type, "u_int64_t")==0) return SDNA_TYPE_UINT64;
else if( strcmp(dna_type, "uint64_t")==0) return SDNA_TYPE_UINT64;
else return -1; /* invalid! */
}
@ -713,7 +713,7 @@ static void cast_elem(const char *ctype, const char *otype, const char *name, ch
case SDNA_TYPE_INT64:
val= *( (int64_t *)olddata); break;
case SDNA_TYPE_UINT64:
val= *( (u_int64_t *)olddata); break;
val= *( (uint64_t *)olddata); break;
}
switch(ctypenr) {
@ -740,7 +740,7 @@ static void cast_elem(const char *ctype, const char *otype, const char *name, ch
case SDNA_TYPE_INT64:
*( (int64_t *)curdata)= val; break;
case SDNA_TYPE_UINT64:
*( (u_int64_t *)curdata)= val; break;
*( (uint64_t *)curdata)= val; break;
}
olddata+= oldlen;

View File

@ -939,7 +939,7 @@ static int make_structDNA(char *baseDirectory, FILE *file)
add_type("float", 4); /* SDNA_TYPE_FLOAT */
add_type("double", 8); /* SDNA_TYPE_DOUBLE */
add_type("int64_t", 8); /* SDNA_TYPE_INT64 */
add_type("u_int64_t", 8); /* SDNA_TYPE_UINT64 */
add_type("uint64_t", 8); /* SDNA_TYPE_UINT64 */
add_type("void", 0); /* SDNA_TYPE_VOID */
// the defines above shouldn't be output in the padding file...

View File

@ -38,13 +38,13 @@
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "MEM_guardedalloc.h"
#include "BKE_cdderivedmesh.h"
#include "BKE_mesh.h"
#include "BKE_modifier.h"
#include "BKE_particle.h"
#include "BKE_cdderivedmesh.h"
#include "MEM_guardedalloc.h"
#ifdef WITH_MOD_DECIMATE
#include "LOD_decimation.h"

View File

@ -47,12 +47,12 @@
#include "BLI_utildefines.h"
#include "BLI_linklist.h"
#include "MEM_guardedalloc.h"
#include "BKE_cdderivedmesh.h"
#include "BKE_modifier.h"
#include "BKE_particle.h"
#include "MEM_guardedalloc.h"
#include "MOD_util.h"

View File

@ -39,13 +39,12 @@
#include "BLI_utildefines.h"
#include "BLI_string.h"
#include "MEM_guardedalloc.h"
#include "BKE_cdderivedmesh.h"
#include "BKE_particle.h"
#include "BKE_deform.h"
#include "MEM_guardedalloc.h"
#include "MOD_modifiertypes.h"
#include "MOD_util.h"

View File

@ -40,16 +40,16 @@
#include "BLI_utildefines.h"
#include "BLI_string.h"
#include "MEM_guardedalloc.h"
#include "BKE_cdderivedmesh.h"
#include "BKE_mesh.h"
#include "BKE_particle.h"
#include "BKE_deform.h"
#include "MOD_modifiertypes.h"
#include "MOD_util.h"
#include "MEM_guardedalloc.h"
typedef struct EdgeFaceRef {
int f1; /* init as -1 */

View File

@ -186,7 +186,7 @@ void wm_event_do_notifiers(bContext *C)
wmWindowManager *wm= CTX_wm_manager(C);
wmNotifier *note, *next;
wmWindow *win;
u_int64_t win_combine_v3d_datamask= 0;
uint64_t win_combine_v3d_datamask= 0;
if(wm==NULL)
return;