[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [34880] branches/particles-2010/source/ blender: Removed 2 deprecated C files.
Lukas Toenne
lukas.toenne at googlemail.com
Tue Feb 15 22:39:27 CET 2011
Revision: 34880
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=34880
Author: lukastoenne
Date: 2011-02-15 21:39:26 +0000 (Tue, 15 Feb 2011)
Log Message:
-----------
Removed 2 deprecated C files.
Removed Paths:
-------------
branches/particles-2010/source/blender/modifiers/intern/MOD_nodetree.c
branches/particles-2010/source/blender/render/intern/source/texture.c
Deleted: branches/particles-2010/source/blender/modifiers/intern/MOD_nodetree.c
===================================================================
--- branches/particles-2010/source/blender/modifiers/intern/MOD_nodetree.c 2011-02-15 19:57:33 UTC (rev 34879)
+++ branches/particles-2010/source/blender/modifiers/intern/MOD_nodetree.c 2011-02-15 21:39:26 UTC (rev 34880)
@@ -1,137 +0,0 @@
-/*
-* ***** BEGIN GPL LICENSE BLOCK *****
-*
-* This program is free software; you can redistribute it and/or
-* modify it under the terms of the GNU General Public License
-* as published by the Free Software Foundation; either version 2
-* of the License, or (at your option) any later version.
-*
-* This program is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-* GNU General Public License for more details.
-*
-* You should have received a copy of the GNU General Public License
-* along with this program; if not, write to the Free Software Foundation,
-* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-*
-* The Original Code is Copyright (C) 2005 by the Blender Foundation.
-* All rights reserved.
-*
-* Contributor(s):
-*
-* ***** END GPL LICENSE BLOCK *****
-*
-*/
-
-/* NodeTree modifier: uses a node tree to define time stepping rules */
-
-#include "DNA_meshdata_types.h"
-#include "DNA_modifier_types.h"
-#include "DNA_node_types.h"
-#include "DNA_object_types.h"
-#include "DNA_particleset_types.h"
-#include "DNA_scene_types.h"
-
-#include "BLI_editVert.h"
-#include "BLI_math.h"
-
-#include "BKE_cdderivedmesh.h"
-#include "BKE_node.h"
-
-#include "MOD_util.h"
-
-#include "depsgraph_private.h"
-#include "MOD_modifiertypes.h"
-#include "MEM_guardedalloc.h"
-
-#include "RNA_access.h"
-#include "RNA_types.h"
-
-static void initData(ModifierData *md)
-{
- NodeTreeModifierData *ntmd= (NodeTreeModifierData*) md;
-
- ntmd->nodetree = NULL;
-}
-static void freeData(ModifierData *md)
-{
-}
-static void copyData(ModifierData *md, ModifierData *target)
-{
- NodeTreeModifierData *ntmd= (NodeTreeModifierData*) md;
- NodeTreeModifierData *tntmd= (NodeTreeModifierData*) target;
-
- tntmd->nodetree = ntmd->nodetree;
-}
-
-static CustomDataMask requiredDataMask(Object *ob, ModifierData *md)
-{
-// NodeTreeModifierData *ntmd= (NodeTreeModifierData*) md;
- CustomDataMask dataMask = 0;
-
- dataMask |= CD_MASK_ORCO;
-
- return dataMask;
-}
-
-static void deformVerts(ModifierData *md, Object *ob, DerivedMesh *derivedData, float (*vertexCos)[3], int numVerts, int useRenderParams, int isFinalCalc)
-{
- NodeTreeModifierData *ntmd= (NodeTreeModifierData*) md;
-
- if(ntmd->nodetree) {
- DerivedMesh *dm= get_cddm(ob, NULL, derivedData, vertexCos);
-
- ntreeSimExecTreeModifier(ntmd->nodetree, md->scene, ob, dm, vertexCos, numVerts, md->scene->r.cfra, 1.0f);
-
- if(dm != derivedData)
- dm->release(dm);
- }
-}
-
-/* disabled in editmode for now */
-static void deformVertsEM(ModifierData *md, Object *ob, EditMesh *editData, DerivedMesh *derivedData, float (*vertexCos)[3], int numVerts)
-{
-#if 0
- DerivedMesh *dm = derivedData;
-
- if(!derivedData) dm = CDDM_from_editmesh(editData, ob->data);
-
- deformVerts(md, ob, dm, vertexCos, numVerts);
-
- if(!derivedData) dm->release(dm);
-#endif
-}
-
-int dependsOnTime(ModifierData *md)
-{
- return 1;
-}
-
-ModifierTypeInfo modifierType_NodeTree = {
- /* name */ "NodeTree",
- /* structName */ "NodeTreeModifierData",
- /* structSize */ sizeof(NodeTreeModifierData),
- /* type */ eModifierTypeType_OnlyDeform,
- /* flags */ eModifierTypeFlag_AcceptsCVs
- | eModifierTypeFlag_AcceptsMesh
- | eModifierTypeFlag_SupportsMapping
- | eModifierTypeFlag_UsesPointCache /*
- | eModifierTypeFlag_SupportsEditmode
- | eModifierTypeFlag_EnableInEditmode */,
-
- /* copyData */ copyData,
- /* deformVerts */ deformVerts,
- /* deformVertsEM */ deformVertsEM,
- /* deformMatricesEM */ 0,
- /* applyModifier */ 0,
- /* applyModifierEM */ 0,
- /* initData */ initData,
- /* requiredDataMask */ requiredDataMask,
- /* freeData */ freeData,
- /* isDisabled */ 0,
- /* updateDepgraph */ 0,
- /* dependsOnTime */ dependsOnTime,
- /* foreachObjectLink */ 0,
- /* foreachIDLink */ 0,
-};
Deleted: branches/particles-2010/source/blender/render/intern/source/texture.c
===================================================================
--- branches/particles-2010/source/blender/render/intern/source/texture.c 2011-02-15 19:57:33 UTC (rev 34879)
+++ branches/particles-2010/source/blender/render/intern/source/texture.c 2011-02-15 21:39:26 UTC (rev 34880)
@@ -1,3146 +0,0 @@
-/*
- * $Id$
- *
- * ***** BEGIN GPL LICENSE BLOCK *****
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- *
- * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * Contributor(s): 2004-2006, Blender Foundation, full recode
- *
- * ***** END GPL LICENSE BLOCK *****
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <math.h>
-
-#include "BLI_blenlib.h"
-#include "BLI_math.h"
-#include "BLI_rand.h"
-#include "BLI_utildefines.h"
-
-#include "DNA_texture_types.h"
-#include "DNA_object_types.h"
-#include "DNA_lamp_types.h"
-#include "DNA_mesh_types.h"
-#include "DNA_meshdata_types.h"
-#include "DNA_material_types.h"
-#include "DNA_image_types.h"
-#include "DNA_node_types.h"
-
-#include "IMB_imbuf_types.h"
-#include "IMB_imbuf.h"
-
-#include "BKE_colortools.h"
-#include "BKE_image.h"
-#include "BKE_node.h"
-#include "BKE_plugin_types.h"
-
-
-#include "BKE_global.h"
-#include "BKE_main.h"
-#include "BKE_material.h"
-
-#include "BKE_library.h"
-#include "BKE_image.h"
-#include "BKE_texture.h"
-#include "BKE_key.h"
-#include "BKE_ipo.h"
-
-#include "envmap.h"
-#include "pointdensity.h"
-#include "voxeldata.h"
-#include "renderpipeline.h"
-#include "render_types.h"
-#include "rendercore.h"
-#include "shading.h"
-#include "texture.h"
-
-#include "renderdatabase.h" /* needed for UV */
-
-/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
-/* defined in pipeline.c, is hardcopy of active dynamic allocated Render */
-/* only to be used here in this file, it's for speed */
-extern struct Render R;
-/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
-
-
-
-
-void init_render_texture(Render *re, Tex *tex)
-{
- int cfra= re->scene->r.cfra;
-
- if(re) cfra= re->r.cfra;
-
- /* imap test */
- if(tex->ima && ELEM(tex->ima->source, IMA_SRC_MOVIE, IMA_SRC_SEQUENCE)) {
- BKE_image_user_calc_frame(&tex->iuser, cfra, re?re->flag & R_SEC_FIELD:0);
- }
-
- if(tex->type==TEX_PLUGIN) {
- if(tex->plugin && tex->plugin->doit) {
- if(tex->plugin->cfra) {
- *(tex->plugin->cfra)= (float)cfra; //BKE_curframe(re->scene); // XXX old animsys - timing stuff to be fixed
- }
- }
- }
- else if(tex->type==TEX_ENVMAP) {
- /* just in case */
- tex->imaflag |= TEX_INTERPOL | TEX_MIPMAP;
- tex->extend= TEX_CLIP;
-
- if(tex->env) {
- if(tex->env->type==ENV_PLANE)
- tex->extend= TEX_EXTEND;
-
- /* only free envmap when rendermode was set to render envmaps, for previewrender */
- if(G.rendering && re) {
- if (re->r.mode & R_ENVMAP)
- if(tex->env->stype==ENV_ANIM)
- BKE_free_envmapdata(tex->env);
- }
- }
- }
-
- if(tex->nodetree && tex->use_nodes) {
- if (!tex->nodetree->execdata)
- tex->nodetree->execdata = ntreeBeginExecTree(tex->nodetree);
- }
-}
-
-/* ------------------------------------------------------------------------- */
-
-void init_render_textures(Render *re)
-{
- Tex *tex;
-
- tex= re->main->tex.first;
- while(tex) {
- if(tex->id.us) init_render_texture(re, tex);
- tex= tex->id.next;
- }
-}
-
-void end_render_texture(Tex *tex)
-{
- if(tex && tex->use_nodes && tex->nodetree) {
- if (tex->nodetree->execdata) {
- ntreeEndExecTree(tex->nodetree->execdata);
- tex->nodetree->execdata = NULL;
- }
- }
-}
-
-void end_render_textures(Render *re)
-{
- Tex *tex;
- for(tex= re->main->tex.first; tex; tex= tex->id.next)
- if(tex->id.us)
- end_render_texture(tex);
-}
-
-/* ------------------------------------------------------------------------- */
-
-
-/* this allows colorbanded textures to control normals as well */
-static void tex_normal_derivate(Tex *tex, TexResult *texres)
-{
- if (tex->flag & TEX_COLORBAND) {
- float col[4];
- if (do_colorband(tex->coba, texres->tin, col)) {
- float fac0, fac1, fac2, fac3;
-
- fac0= (col[0]+col[1]+col[2]);
- do_colorband(tex->coba, texres->nor[0], col);
- fac1= (col[0]+col[1]+col[2]);
- do_colorband(tex->coba, texres->nor[1], col);
- fac2= (col[0]+col[1]+col[2]);
- do_colorband(tex->coba, texres->nor[2], col);
- fac3= (col[0]+col[1]+col[2]);
-
- texres->nor[0]= 0.3333*(fac0 - fac1);
- texres->nor[1]= 0.3333*(fac0 - fac2);
- texres->nor[2]= 0.3333*(fac0 - fac3);
-
- return;
- }
- }
- texres->nor[0]= texres->tin - texres->nor[0];
- texres->nor[1]= texres->tin - texres->nor[1];
- texres->nor[2]= texres->tin - texres->nor[2];
-}
-
-
-
-static int blend(Tex *tex, float *texvec, TexResult *texres)
-{
- float x, y, t;
-
- if(tex->flag & TEX_FLIPBLEND) {
- x= texvec[1];
- y= texvec[0];
- }
- else {
- x= texvec[0];
- y= texvec[1];
- }
-
- if(tex->stype==TEX_LIN) { /* lin */
- texres->tin= (1.0+x)/2.0;
- }
- else if(tex->stype==TEX_QUAD) { /* quad */
- texres->tin= (1.0+x)/2.0;
- if(texres->tin<0.0) texres->tin= 0.0;
- else texres->tin*= texres->tin;
- }
- else if(tex->stype==TEX_EASE) { /* ease */
- texres->tin= (1.0+x)/2.0;
- if(texres->tin<=.0) texres->tin= 0.0;
- else if(texres->tin>=1.0) texres->tin= 1.0;
- else {
- t= texres->tin*texres->tin;
- texres->tin= (3.0*t-2.0*t*texres->tin);
- }
- }
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list