Scons build system. MSVC 7.1 in a moment.

This commit is contained in:
Robert Holcomb
2007-03-24 18:41:54 +00:00
parent d193ce012a
commit 808a5fc05a
26 changed files with 356 additions and 1261 deletions
+5 -5
View File
@@ -5,13 +5,13 @@ WITH_BF_VERSE = 'false'
BF_VERSE_INCLUDE = "#extern/verse/dist"
BF_PYTHON = '/usr'
BF_PYTHON_VERSION = '2.5'
BF_PYTHON_VERSION = '2.4'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}' #BF_PYTHON+'/lib/python'+BF_PYTHON_VERSION+'/config/libpython'+BF_PYTHON_VERSION+'.a'
BF_PYTHON_LINKFLAGS = ['-Xlinker', '-export-dynamic']
WITH_BF_OPENAL = 'true'
WITH_BF_OPENAL = 'false'
BF_OPENAL = '/usr'
BF_OPENAL_INC = '${BF_OPENAL}/include'
BF_OPENAL_LIB = 'openal'
@@ -128,8 +128,8 @@ BF_OPENGL_LIBPATH = '/usr/X11R6/lib'
BF_OPENGL_LIB_STATIC = '${BF_OPENGL}/libGL.a ${BF_OPENGL}/libGLU.a ${BF_OPENGL}/libXxf86vm.a ${BF_OPENGL}/libX11.a ${BF_OPENGL}/libXi.a ${BF_OPENGL}/libXext.a ${BF_OPENGL}/libXxf86vm.a'
##
CC = 'gcc'
CXX = 'g++'
CC = 'gcc -march=athlon -m3dnow -mmmx -msse -msse2'
CXX = 'g++ -march=athlon -m3dnow -mmmx -msse -msse2'
##ifeq ($CPU),alpha)
## CFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing -mieee
@@ -166,4 +166,4 @@ BF_INSTALLDIR='../install/linux2'
#Link against pthread
PLATFORM_LINKFLAGS = ['-pthread']
PLATFORM_LINKFLAGS = ['-pthread']
+16 -13
View File
@@ -328,10 +328,8 @@ processEvents(
}
void
GHOST_SystemX11::
processEvent(
XEvent *xe
){
GHOST_SystemX11::processEvent(XEvent *xe)
{
GHOST_WindowX11 * window = findGhostWindow(xe->xany.window);
GHOST_Event * g_event = NULL;
@@ -507,17 +505,22 @@ processEvent(
case ReparentNotify:
break;
default: {
if(xe->type == window->GetXTablet().MotionEvent) {
default: {
if(xe->type == window->GetXTablet().MotionEvent)
{
XDeviceMotionEvent* data = (XDeviceMotionEvent*)xe;
window->GetXTablet().CommonData.Pressure= data->axis_data[2]/((float)window->GetXTablet().PressureLevels);
/* the (short) cast and the &0xffff is bizarre and unexplained anywhere,
* but I got garbage data without it. Found it in the xidump.c source --matt */
window->GetXTablet().CommonData.Xtilt= (short)(data->axis_data[3]&0xffff)/((float)window->GetXTablet().XtiltLevels);
window->GetXTablet().CommonData.Ytilt= (short)(data->axis_data[4]&0xffff)/((float)window->GetXTablet().YtiltLevels);
window->GetXTablet().CommonData.Pressure=
data->axis_data[2]/((float)window->GetXTablet().PressureLevels);
/* the (short) cast and the &0xffff is bizarre and unexplained anywhere,
* but I got garbage data without it. Found it in the xidump.c source --matt */
window->GetXTablet().CommonData.Xtilt=
(short)(data->axis_data[3]&0xffff)/((float)window->GetXTablet().XtiltLevels);
window->GetXTablet().CommonData.Ytilt=
(short)(data->axis_data[4]&0xffff)/((float)window->GetXTablet().YtiltLevels);
}
else if(xe->type == window->GetXTablet().ProxInEvent) {
else if(xe->type == window->GetXTablet().ProxInEvent)
{
XProximityNotifyEvent* data = (XProximityNotifyEvent*)xe;
if(data->deviceid == window->GetXTablet().StylusID)
window->GetXTablet().CommonData.Active= 1;
+2 -1
View File
@@ -14,7 +14,8 @@ SConscript(['avi/SConscript',
'radiosity/SConscript',
'readblenfile/SConscript',
'render/SConscript',
'src/SConscript'])
'src/SConscript',
'nodes/SConscript'])
if env['WITH_BF_YAFRAY'] == 1:
SConscript(['yafray/SConscript'])
+58 -53
View File
@@ -33,6 +33,8 @@
#ifndef BKE_NODE_H
#define BKE_NODE_H
struct ID;
struct bNodeTree;
struct bNode;
@@ -78,17 +80,19 @@ typedef struct bNodeType {
/* after this line is set on startup of blender */
int (*butfunc)(struct uiBlock *, struct bNodeTree *, struct bNode *, struct rctf *);
void (*initfunc)(struct bNode *);
} bNodeType;
/* nodetype->nclass, for add-menu and themes */
#define NODE_CLASS_INPUT 0
#define NODE_CLASS_OUTPUT 1
#define NODE_CLASS_OP_COLOR 3
#define NODE_CLASS_OP_VECTOR 4
#define NODE_CLASS_OP_FILTER 5
#define NODE_CLASS_OP_VECTOR 4
#define NODE_CLASS_OP_FILTER 5
#define NODE_CLASS_GROUP 6
#define NODE_CLASS_FILE 7
#define NODE_CLASS_CONVERTOR 8
#define NODE_CLASS_CONVERTOR 8
#define NODE_CLASS_MATTE 9
#define NODE_CLASS_DISTORT 10
@@ -151,7 +155,7 @@ void nodeGroupSocketUseFlags(struct bNodeTree *ngroup);
/* ************** COMMON NODES *************** */
#define NODE_GROUP 2
#define NODE_GROUP 2
#define NODE_GROUP_MENU 1000
extern bNodeType node_group_typeinfo;
@@ -169,7 +173,7 @@ struct ShadeResult;
#define SH_NODE_OUTPUT 1
#define SH_NODE_MATERIAL 100
#define SH_NODE_RGB 101
#define SH_NODE_RGB 101
#define SH_NODE_VALUE 102
#define SH_NODE_MIX_RGB 103
#define SH_NODE_VALTORGB 104
@@ -183,14 +187,13 @@ struct ShadeResult;
#define SH_NODE_CAMERA 114
#define SH_NODE_MATH 115
#define SH_NODE_VECT_MATH 116
#define SH_NODE_SQUEEZE 117
/* custom defines: options for Material node */
#define SH_NODE_MAT_DIFF 1
#define SH_NODE_MAT_SPEC 2
#define SH_NODE_MAT_NEG 4
#define SH_NODE_SQUEEZE 117
/* the type definitions array */
extern bNodeType *node_all_shaders[];
static bNodeType *node_all_shaders[];
/* API */
@@ -199,10 +202,29 @@ void ntreeShaderGetTexcoMode(struct bNodeTree *ntree, int osa, short *texco, i
void nodeShaderSynchronizeID(struct bNode *node, int copyto);
/* switch material render loop */
void (*node_shader_lamp_loop)(struct ShadeInput *, struct ShadeResult *);
void set_node_shader_lamp_loop(void (*lamp_loop_func)(struct ShadeInput *, struct ShadeResult *));
/* ************** COMPOSITE NODES *************** */
/* output socket defines */
#define RRES_OUT_IMAGE 0
#define RRES_OUT_ALPHA 1
#define RRES_OUT_Z 2
#define RRES_OUT_NORMAL 3
#define RRES_OUT_UV 4
#define RRES_OUT_VEC 5
#define RRES_OUT_RGBA 6
#define RRES_OUT_DIFF 7
#define RRES_OUT_SPEC 8
#define RRES_OUT_SHADOW 9
#define RRES_OUT_AO 10
#define RRES_OUT_REFLECT 11
#define RRES_OUT_REFRACT 12
#define RRES_OUT_RADIO 13
#define RRES_OUT_INDEXOB 14
/* note: types are needed to restore callbacks, don't change values */
#define CMP_NODE_VIEWER 201
#define CMP_NODE_RGB 202
@@ -223,56 +245,39 @@ void set_node_shader_lamp_loop(void (*lamp_loop_func)(struct ShadeInput *, str
#define CMP_NODE_SEPHSVA 217
#define CMP_NODE_SETALPHA 218
#define CMP_NODE_HUE_SAT 219
#define CMP_NODE_IMAGE 220
#define CMP_NODE_R_LAYERS 221
#define CMP_NODE_COMPOSITE 222
#define CMP_NODE_IMAGE 220
#define CMP_NODE_R_LAYERS 221
#define CMP_NODE_COMPOSITE 222
#define CMP_NODE_OUTPUT_FILE 223
#define CMP_NODE_TEXTURE 224
#define CMP_NODE_TRANSLATE 225
#define CMP_NODE_ZCOMBINE 226
#define CMP_NODE_COMBRGBA 227
#define CMP_NODE_TEXTURE 224
#define CMP_NODE_TRANSLATE 225
#define CMP_NODE_ZCOMBINE 226
#define CMP_NODE_COMBRGBA 227
#define CMP_NODE_DILATEERODE 228
#define CMP_NODE_ROTATE 229
#define CMP_NODE_SCALE 230
#define CMP_NODE_SEPYCCA 231
#define CMP_NODE_COMBYCCA 232
#define CMP_NODE_SEPYUVA 233
#define CMP_NODE_COMBYUVA 234
#define CMP_NODE_DIFF_MATTE 235
#define CMP_NODE_ROTATE 229
#define CMP_NODE_SCALE 230
#define CMP_NODE_SEPYCCA 231
#define CMP_NODE_COMBYCCA 232
#define CMP_NODE_SEPYUVA 233
#define CMP_NODE_COMBYUVA 234
#define CMP_NODE_DIFF_MATTE 235
#define CMP_NODE_COLOR_SPILL 236
#define CMP_NODE_CHROMA 237
#define CMP_NODE_CHROMA 237
#define CMP_NODE_CHANNEL_MATTE 238
#define CMP_NODE_FLIP 239
#define CMP_NODE_FLIP 239
#define CMP_NODE_SPLITVIEWER 240
#define CMP_NODE_INDEX_MASK 241
#define CMP_NODE_MAP_UV 242
#define CMP_NODE_ID_MASK 243
#define CMP_NODE_DEFOCUS 244
#define CMP_NODE_DISPLACE 245
#define CMP_NODE_COMBHSVA 246
#define CMP_NODE_MATH 247
#define CMP_NODE_LUMA_MATTE 248
#define CMP_NODE_INDEX_MASK 241
#define CMP_NODE_MAP_UV 242
#define CMP_NODE_ID_MASK 243
#define CMP_NODE_DEFOCUS 244
#define CMP_NODE_DISPLACE 245
#define CMP_NODE_COMBHSVA 246
#define CMP_NODE_MATH 247
#define CMP_NODE_LUMA_MATTE 248
/* filter types */
/* filter types, in custom1 */
#define CMP_FILT_SOFT 0
#define CMP_FILT_SHARP 1
#define CMP_FILT_LAPLACE 2
#define CMP_FILT_SOBEL 3
#define CMP_FILT_PREWITT 4
#define CMP_FILT_KIRSCH 5
#define CMP_FILT_SHADOW 6
/* scale node type, in custom1 */
#define CMP_SCALE_RELATIVE 0
#define CMP_SCALE_ABSOLUTE 1
/* the type definitions array */
extern bNodeType *node_all_composit[];
static bNodeType* node_all_composit[];
/* API */
struct CompBuf;
+1 -1
View File
@@ -5,7 +5,7 @@ sources = env.Glob('intern/*.c')
incs = '. #/intern/guardedalloc ../include ../blenlib ../makesdna'
incs += ' ../python ../render/extern/include #/intern/decimation/extern'
incs += ' ../imbuf ../avi #/intern/elbeem/extern'
incs += ' ../imbuf ../avi #/intern/elbeem/extern ../nodes'
incs += ' #/intern/iksolver/extern ../blenloader ../quicktime'
incs += ' ' + env['BF_OPENGL_INC']
+156 -126
View File
@@ -56,6 +56,13 @@
#include "MEM_guardedalloc.h"
#include "IMB_imbuf.h"
#include "RE_pipeline.h"
#include "RE_shader_ext.h" /* <- TexResult */
#include "RE_render_ext.h" /* <- ibuf_sample() */
#include "CMP_node.h"
#include "SHD_node.h"
/* not very important, but the stack solver likes to know a maximum */
#define MAX_SOCKET 64
@@ -774,132 +781,9 @@ bNode *nodeAddNodeType(bNodeTree *ntree, int type, bNodeTree *ngroup)
}
/* need init handler later? */
if(ntree->type==NTREE_SHADER) {
if(type==SH_NODE_MATERIAL)
node->custom1= SH_NODE_MAT_DIFF|SH_NODE_MAT_SPEC;
else if(type==SH_NODE_VALTORGB)
node->storage= add_colorband(1);
else if(type==SH_NODE_MAPPING)
node->storage= add_mapping();
else if(type==SH_NODE_CURVE_VEC)
node->storage= curvemapping_add(3, -1.0f, -1.0f, 1.0f, 1.0f);
else if(type==SH_NODE_CURVE_RGB)
node->storage= curvemapping_add(4, 0.0f, 0.0f, 1.0f, 1.0f);
else if(type==SH_NODE_GEOMETRY)
node->storage= MEM_callocN(sizeof(NodeGeometry), "NodeGeometry");
}
else if(ntree->type==NTREE_COMPOSIT) {
if(type==CMP_NODE_VALTORGB)
node->storage= add_colorband(1);
else if(type==CMP_NODE_CURVE_VEC)
node->storage= curvemapping_add(3, -1.0f, -1.0f, 1.0f, 1.0f);
else if(type==CMP_NODE_CURVE_RGB)
node->storage= curvemapping_add(4, 0.0f, 0.0f, 1.0f, 1.0f);
else if(type==CMP_NODE_TIME) {
node->custom1= G.scene->r.sfra;
node->custom2= G.scene->r.efra;
node->storage= curvemapping_add(1, 0.0f, 0.0f, 1.0f, 1.0f);
}
else if(type==CMP_NODE_MAP_VALUE)
node->storage= add_mapping();
else if(type==CMP_NODE_BLUR)
node->storage= MEM_callocN(sizeof(NodeBlurData), "node blur data");
else if(type==CMP_NODE_DEFOCUS) {
/* qdn: defocus node */
NodeDefocus *nbd = MEM_callocN(sizeof(NodeDefocus), "node defocus data");
nbd->bktype = 0;
nbd->rotation = 0.f;
nbd->preview = 1;
nbd->gamco = 0;
nbd->samples = 16;
nbd->fstop = 128.f;
nbd->maxblur = 0;
nbd->bthresh = 1.f;
nbd->scale = 1.f;
nbd->no_zbuf = 1;
node->storage = nbd;
}
else if(type==CMP_NODE_VECBLUR) {
NodeBlurData *nbd= MEM_callocN(sizeof(NodeBlurData), "node blur data");
node->storage= nbd;
nbd->samples= 32;
nbd->fac= 1.0f;
}
else if(ELEM3(type, CMP_NODE_IMAGE, CMP_NODE_VIEWER, CMP_NODE_SPLITVIEWER)) {
ImageUser *iuser= MEM_callocN(sizeof(ImageUser), "node image user");
node->storage= iuser;
iuser->sfra= 1;
iuser->fie_ima= 2;
iuser->ok= 1;
if(type==CMP_NODE_SPLITVIEWER){
node->custom1= 50; /* default 50% split */
}
}
else if(type==CMP_NODE_HUE_SAT) {
NodeHueSat *nhs= MEM_callocN(sizeof(NodeHueSat), "node hue sat");
node->storage= nhs;
nhs->hue= 0.5f;
nhs->sat= 1.0f;
nhs->val= 1.0f;
}
else if(type==CMP_NODE_OUTPUT_FILE) {
NodeImageFile *nif= MEM_callocN(sizeof(NodeImageFile), "node image file");
node->storage= nif;
BLI_strncpy(nif->name, G.scene->r.pic, sizeof(nif->name));
nif->imtype= G.scene->r.imtype;
nif->subimtype= G.scene->r.subimtype;
nif->quality= G.scene->r.quality;
nif->sfra= G.scene->r.sfra;
nif->efra= G.scene->r.efra;
}
else if(type==CMP_NODE_DIFF_MATTE){
NodeChroma *c= MEM_callocN(sizeof(NodeChroma), "node chroma");
node->storage= c;
c->t1= 0.01f;
c->t2= 0.01f;
c->t3= 0.01f;
c->fsize= 0.0f;
c->fstrength= 0.0f;
node->custom1= 1; /* RGB */
}
else if(type==CMP_NODE_COLOR_SPILL){
NodeChroma *c= MEM_callocN(sizeof(NodeChroma), "node chroma");
node->storage=c;
c->t1= 0.0f;
c->t2= 0.0f;
c->t3= 0.0f;
c->fsize= 0.0f;
c->fstrength= 0.0f;
node->custom1= 2; /* green channel */
}
else if(type==CMP_NODE_CHROMA){
NodeChroma *c= MEM_callocN(sizeof(NodeChroma), "node chroma");
node->storage= c;
c->t1= 30.0f;
c->t2= 10.0f;
c->t3= 0.0f;
c->fsize= 0.0f;
c->fstrength= 1.0f;
}
else if(type==CMP_NODE_CHANNEL_MATTE){
NodeChroma *c= MEM_callocN(sizeof(NodeChroma), "node chroma");
node->storage=c;
c->t1= 0.0f;
c->t2= 0.0f;
c->t3= 0.0f;
c->fsize= 0.0f;
c->fstrength= 0.0f;
node->custom1= 1; /* RGB channel */
node->custom2= 2; /* Green Channel */
}
else if(type==CMP_NODE_LUMA_MATTE){
NodeChroma *c= MEM_callocN(sizeof(NodeChroma), "node chroma");
node->storage=c;
c->t1= 0.0f;
c->t2= 0.0f;
}
}
/* got it-bob*/
if(ntype->initfunc!=NULL)
ntype->initfunc(node);
return node;
}
@@ -2266,3 +2150,149 @@ void ntreeCompositExecTree(bNodeTree *ntree, RenderData *rd, int do_preview)
}
/* **************** call to switch lamploop for material node ************ */
void set_node_shader_lamp_loop(void (*lamp_loop_func)(ShadeInput *, ShadeResult *))
{
node_shader_lamp_loop= lamp_loop_func;
}
/* clumsy checking... should do dynamic outputs once */
static void force_hidden_passes(bNode *node, int passflag)
{
bNodeSocket *sock;
for(sock= node->outputs.first; sock; sock= sock->next)
sock->flag &= ~SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_Z);
if(!(passflag & SCE_PASS_Z)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_NORMAL);
if(!(passflag & SCE_PASS_NORMAL)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_VEC);
if(!(passflag & SCE_PASS_VECTOR)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_UV);
if(!(passflag & SCE_PASS_UV)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_RGBA);
if(!(passflag & SCE_PASS_RGBA)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_DIFF);
if(!(passflag & SCE_PASS_DIFFUSE)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_SPEC);
if(!(passflag & SCE_PASS_SPEC)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_SHADOW);
if(!(passflag & SCE_PASS_SHADOW)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_AO);
if(!(passflag & SCE_PASS_AO)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_REFLECT);
if(!(passflag & SCE_PASS_REFLECT)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_REFRACT);
if(!(passflag & SCE_PASS_REFRACT)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_RADIO);
if(!(passflag & SCE_PASS_RADIO)) sock->flag |= SOCK_UNAVAIL;
sock= BLI_findlink(&node->outputs, RRES_OUT_INDEXOB);
if(!(passflag & SCE_PASS_INDEXOB)) sock->flag |= SOCK_UNAVAIL;
}
/* based on rules, force sockets hidden always */
void ntreeCompositForceHidden(bNodeTree *ntree)
{
bNode *node;
if(ntree==NULL) return;
for(node= ntree->nodes.first; node; node= node->next) {
if( node->type==CMP_NODE_R_LAYERS) {
Scene *sce= node->id?(Scene *)node->id:G.scene; /* G.scene is WEAK! */
SceneRenderLayer *srl= BLI_findlink(&sce->r.layers, node->custom1);
if(srl)
force_hidden_passes(node, srl->passflag);
}
else if( node->type==CMP_NODE_IMAGE) {
Image *ima= (Image *)node->id;
if(ima) {
if(ima->rr) {
ImageUser *iuser= node->storage;
RenderLayer *rl= BLI_findlink(&ima->rr->layers, iuser->layer);
if(rl)
force_hidden_passes(node, rl->passflag);
else
force_hidden_passes(node, 0);
}
else if(ima->type!=IMA_TYPE_MULTILAYER) { /* if ->rr not yet read we keep inputs */
force_hidden_passes(node, RRES_OUT_Z);
}
}
else
force_hidden_passes(node, 0);
}
}
}
/* called from render pipeline, to tag render input and output */
/* need to do all scenes, to prevent errors when you re-render 1 scene */
void ntreeCompositTagRender(Scene *curscene)
{
Scene *sce;
for(sce= G.main->scene.first; sce; sce= sce->id.next) {
if(sce->nodetree) {
bNode *node;
for(node= sce->nodetree->nodes.first; node; node= node->next) {
if(node->id==(ID *)curscene || node->type==CMP_NODE_COMPOSITE)
NodeTagChanged(sce->nodetree, node);
}
}
}
}
/* tags nodes that have animation capabilities */
int ntreeCompositTagAnimated(bNodeTree *ntree)
{
bNode *node;
int tagged= 0;
if(ntree==NULL) return 0;
for(node= ntree->nodes.first; node; node= node->next) {
if(node->type==CMP_NODE_IMAGE) {
Image *ima= (Image *)node->id;
if(ima && ELEM(ima->source, IMA_SRC_MOVIE, IMA_SRC_SEQUENCE)) {
NodeTagChanged(ntree, node);
tagged= 1;
}
}
else if(node->type==CMP_NODE_TIME) {
NodeTagChanged(ntree, node);
tagged= 1;
}
else if(node->type==CMP_NODE_R_LAYERS) {
NodeTagChanged(ntree, node);
tagged= 1;
}
else if(node->type==NODE_GROUP) {
if( ntreeCompositTagAnimated((bNodeTree *)node->id) ) {
NodeTagChanged(ntree, node);
}
}
}
return tagged;
}
/* called from image window preview */
void ntreeCompositTagGenerators(bNodeTree *ntree)
{
bNode *node;
if(ntree==NULL) return;
for(node= ntree->nodes.first; node; node= node->next) {
if( ELEM(node->type, CMP_NODE_R_LAYERS, CMP_NODE_IMAGE))
NodeTagChanged(ntree, node);
}
}
+32
View File
@@ -97,6 +97,38 @@ void node_draw_link(struct SpaceNode *snode, struct bNodeLink *link);
void init_node_butfuncs(void);
/* exported to CMP and SHD nodes */
void node_ID_title_cb(void *node_v, void *unused_v);
void node_but_title_cb(void *node_v, void *but_v);
void node_texmap_cb(void *texmap_v, void *unused_v);
//void node_new_mat_cb(void *ntree_v, void *node_v);
//void node_browse_mat_cb(void *ntree_v, void *node_v);
//void node_mat_alone_cb(void *node_v, void *unused);
//void node_browse_image_cb(void *ntree_v, void *node_v);
//void node_active_cb(void *ntree_v, void *node_v);
//void node_image_type_cb(void *node_v, void *unused);
//char *node_image_type_pup(void);
//char *layer_menu(struct RenderResult *rr);
//void image_layer_cb(void *ima_v, void *iuser_v);
//void set_render_layers_title(void *node_v, void *unused);
//char *scene_layer_menu(struct Scene *sce);
//void node_browse_scene_cb(void *ntree_v, void *node_v);
int node_buts_curvevec(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_curvecol(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_rgb(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_texture(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_valtorgb(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_value(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_mix_rgb(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_group(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_normal(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr);
int node_buts_math(struct uiBlock *block, struct bNodeTree *ntree, struct bNode *node, struct rctf *butr) ;
/* ************* Shader nodes ***************** */
+1 -1
View File
@@ -104,7 +104,7 @@ extern bNodeType cmp_node_flip;
extern bNodeType cmp_node_displace;
extern bNodeType cmp_node_mapuv;
static bNodeType *node_all_composit[]= {
static bNodeType* node_all_composit[]= {
&node_group_typeinfo,
&cmp_node_rlayers,
+3 -1
View File
@@ -5,13 +5,15 @@ sources = env.Glob('intern/*.c')
sources += env.Glob('intern/CMP_nodes/*.c')
sources += env.Glob('intern/SHD_nodes/*.c')
incs = '. #/intern/guardedalloc ../include ../blenlib ../makesdna'
incs = '. ./intern '
incs += '#/intern/guardedalloc ../include ../blenlib ../makesdna'
incs += ' ../python ../render/extern/include '
incs += ' ../imbuf ../avi '
incs += ' ../blenloader ../quicktime'
incs += ' ../blenkernel ../renderconverter '
incs += ' ' + env['BF_OPENGL_INC']
incs += ' ' + env['BF_ZLIB_INC']
incs += ' ' + env['BF_SDL_INC']
+7 -3
View File
@@ -40,7 +40,6 @@
#define SH_NODE_MAT_SPEC 2
#define SH_NODE_MAT_NEG 4
/* the type definitions array */
/* ****************** types array for all shaders ****************** */
@@ -62,8 +61,8 @@ extern bNodeType sh_node_math;
extern bNodeType sh_node_vect_math;
extern bNodeType sh_node_squeeze;
static bNodeType *node_all_shaders[]= {
&node_group_typeinfo,
static bNodeType* node_all_shaders[]= {
&node_group_typeinfo,
&sh_node_output,
&sh_node_material,
&sh_node_camera,
@@ -83,4 +82,9 @@ static bNodeType *node_all_shaders[]= {
&sh_node_squeeze,
NULL
};
#endif
@@ -130,4 +130,6 @@ bNodeType cmp_node_alphaover= {
/* execfunc */ node_composit_exec_alphaover,
/* butfunc */ node_composit_buts_alphaover
};
};
@@ -660,4 +660,6 @@ bNodeType cmp_node_blur= {
/* execfunc */ node_composit_exec_blur,
/* butfunc */ node_composit_buts_blur,
node_composit_init_blur
};
};
@@ -213,4 +213,6 @@ bNodeType cmp_node_chroma={
/* execfunc */ node_composit_exec_chroma_matte,
/* butfunc */ node_composit_buts_chroma_matte,
node_composit_init_chroma_matte
};
};
@@ -109,4 +109,6 @@ bNodeType cmp_node_flip= {
/* storage */ "",
/* execfunc */ node_composit_exec_flip,
/* butfunc */ node_composit_buts_flip
};
};
@@ -636,4 +636,6 @@ bNodeType cmp_node_rlayers= {
/* butfunc */ node_composit_buts_renderlayers,
NULL
};
};
@@ -169,4 +169,6 @@ bNodeType cmp_node_output_file= {
/* butfunc */ node_composit_buts_output_file,
node_composit_init_output_file
};
};
@@ -182,4 +182,6 @@ bNodeType cmp_node_combycca= {
/* storage */ "",
/* execfunc */ node_composit_exec_combycca,
/* butfunc */ NULL
};
};
@@ -125,5 +125,6 @@ bNodeType cmp_node_vecblur= {
/* output sock */ cmp_node_vecblur_out,
/* storage */ "NodeBlurData",
/* execfunc */ node_composit_exec_vecblur,
/* butfunc */ node_composit_buts_vecblur
/* butfunc */ node_composit_buts_vecblur,
node_composit_init_vecblur
};
+4 -1
View File
@@ -29,6 +29,9 @@
#include "CMP_util.h"
CompBuf *alloc_compbuf(int sizex, int sizey, int type, int alloc)
{
CompBuf *cbuf= MEM_callocN(sizeof(CompBuf), "compbuf");
@@ -573,4 +576,4 @@ void gamma_correct_compbuf(CompBuf *img, int inversed)
if(drect[2]>0.0f) drect[2]*= drect[2]; else drect[2]= 0.0f;
}
}
}
}
+3 -1
View File
@@ -59,8 +59,9 @@
#include "BKE_material.h"
#include "BKE_texture.h"
#include "BKE_utildefines.h"
#include "BKE_library.h"
#include "..\CMP_node.h"
#include "../CMP_node.h"
#include "BIF_gl.h"
@@ -88,6 +89,7 @@
#include "RE_pipeline.h"
#include "RE_shader_ext.h"
#include "RE_render_ext.h"
#include "butspace.h"
#include "blendef.h"
@@ -27,7 +27,7 @@
* ***** END GPL LICENSE BLOCK *****
*/
#include "..\SHD_util.h"
#include "../SHD_util.h"
/* **************** CAMERA INFO ******************** */
static bNodeSocketType sh_node_camera_out[]= {
@@ -28,7 +28,7 @@
*/
#include "..\SHD_util.h"
#include "../SHD_util.h"
/* **************** VECTOR MATH ******************** */
+3
View File
@@ -30,6 +30,9 @@
#include "SHD_util.h"
/* ****** */
void nodestack_get_vec(float *in, short type_in, bNodeStack *ns)
+7 -3
View File
@@ -30,6 +30,9 @@
#ifndef SHD_NODE_UTIL_H_
#define SHD_NODE_UTIL_H_
#include <math.h>
#include <string.h>
#include "MEM_guardedalloc.h"
#include "DNA_action_types.h"
@@ -54,8 +57,9 @@
#include "BKE_material.h"
#include "BKE_texture.h"
#include "BKE_utildefines.h"
#include "BKE_library.h"
#include "..\SHD_node.h"
#include "../SHD_node.h"
#include "BIF_gl.h"
#include "BIF_glutil.h"
@@ -112,6 +116,6 @@ typedef struct ShaderCallData {
extern void node_ID_title_cb(void *node_v, void *unused_v);
void nodestack_get_vec(float *in, short type_in, bNodeStack *ns);
#endif
#endif
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -859,7 +859,7 @@ void BIF_init(void)
initbuttons();
InitCursorData();
sound_init_listener();
init_node_butfuncs();
/*init_node_butfuncs();*/ /*removed because nodes now take care of themselves */
BIF_preview_init_dbase();
BIF_read_homefile(0);