[Bf-blender-cvs] [7658d73] hair_system: Skeleton structs for Hair system, based on curves and points.

Lukas Tönne noreply at git.blender.org
Thu Jul 24 14:49:36 CEST 2014


Commit: 7658d73ee2dc94bcca5b7ca889fbf079f235a3ff
Author: Lukas Tönne
Date:   Thu Jul 24 11:51:16 2014 +0200
Branches: hair_system
https://developer.blender.org/rB7658d73ee2dc94bcca5b7ca889fbf079f235a3ff

Skeleton structs for Hair system, based on curves and points.

===================================================================

M	source/blender/CMakeLists.txt
A	source/blender/blenkernel/BKE_hair.h
M	source/blender/blenkernel/CMakeLists.txt
A	source/blender/blenkernel/intern/hair.c
A	source/blender/hair/CMakeLists.txt
A	source/blender/makesdna/DNA_hair_types.h
M	source/blender/makesdna/intern/makesdna.c

===================================================================

diff --git a/source/blender/CMakeLists.txt b/source/blender/CMakeLists.txt
index 0d30952..ac93961 100644
--- a/source/blender/CMakeLists.txt
+++ b/source/blender/CMakeLists.txt
@@ -90,6 +90,7 @@ set(SRC_DNA_INC
 	${CMAKE_CURRENT_SOURCE_DIR}/makesdna/DNA_movieclip_types.h
 	${CMAKE_CURRENT_SOURCE_DIR}/makesdna/DNA_tracking_types.h
 	${CMAKE_CURRENT_SOURCE_DIR}/makesdna/DNA_mask_types.h
+	${CMAKE_CURRENT_SOURCE_DIR}/makesdna/DNA_hair_types.h
 )
 
 add_subdirectory(datatoc)
diff --git a/source/blender/blenkernel/BKE_hair.h b/source/blender/blenkernel/BKE_hair.h
new file mode 100644
index 0000000..e5077df
--- /dev/null
+++ b/source/blender/blenkernel/BKE_hair.h
@@ -0,0 +1,38 @@
+/*
+ * ***** 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) 2014 Blender Foundation.
+ * All rights reserved.
+ *
+ * Contributor(s): Blender Foundation,
+ *                 Lukas Toenne
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#ifndef __BKE_HAIR_H__
+#define __BKE_HAIR_H__
+
+/** \file BKE_hair.h
+ *  \ingroup bke
+ */
+
+struct HairSystem;
+
+void BKE_hair_calc_curve_offsets(HairSystem *hsys);
+
+#endif
diff --git a/source/blender/blenkernel/CMakeLists.txt b/source/blender/blenkernel/CMakeLists.txt
index 0caf7d1..a6de5d4 100644
--- a/source/blender/blenkernel/CMakeLists.txt
+++ b/source/blender/blenkernel/CMakeLists.txt
@@ -97,6 +97,7 @@ set(SRC
 	intern/freestyle.c
 	intern/gpencil.c
 	intern/group.c
+	intern/hair.c
 	intern/icons.c
 	intern/idcode.c
 	intern/idprop.c
@@ -208,6 +209,7 @@ set(SRC
 	BKE_global.h
 	BKE_gpencil.h
 	BKE_group.h
+	BKE_hair.h
 	BKE_icons.h
 	BKE_idcode.h
 	BKE_idprop.h
diff --git a/source/blender/blenkernel/intern/hair.c b/source/blender/blenkernel/intern/hair.c
new file mode 100644
index 0000000..ebc0a30
--- /dev/null
+++ b/source/blender/blenkernel/intern/hair.c
@@ -0,0 +1,45 @@
+/*
+ * ***** 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) 2014 Blender Foundation.
+ * All rights reserved.
+ *
+ * Contributor(s): Blender Foundation,
+ *                 Lukas Toenne
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+/** \file blender/blenkernel/intern/hair.c
+ *  \ingroup bke
+ */
+
+#include "DNA_hair_types.h"
+
+#include "BKE_hair.h"
+
+void BKE_hair_calc_curve_offsets(HairSystem *hsys)
+{
+	HairCurve *hair;
+	int a;
+	int offset = 0;
+	
+	for (a = 0, hair = hsys->curves; a < hsys->totcurves; ++a, ++hair) {
+		hair->offset = offset;
+		offset += hair->numpoints;
+	}
+}
diff --git a/source/blender/hair/CMakeLists.txt b/source/blender/hair/CMakeLists.txt
new file mode 100644
index 0000000..a194334
--- /dev/null
+++ b/source/blender/hair/CMakeLists.txt
@@ -0,0 +1,538 @@
+# ***** 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) 2011, Blender Foundation
+# All rights reserved.
+#
+# The Original Code is: all of this file.
+#
+# Contributor(s): Jeroen Bakker, Monique Dewanchand, Blender Developers Fund.
+#
+# ***** END GPL LICENSE BLOCK *****
+
+set(INC
+	.
+	intern
+	nodes
+	operations
+	../blenkernel
+	../blenlib
+	../imbuf
+	../makesdna
+	../makesrna
+	../windowmanager
+	../nodes
+	../nodes/composite
+	../nodes/intern
+	../render/extern/include
+	../render/intern/include
+	../../../intern/opencl
+	../../../intern/guardedalloc
+)
+
+set(INC_SYS
+
+)
+
+set(SRC
+	COM_compositor.h
+	COM_defines.h
+
+	intern/COM_compositor.cpp
+	intern/COM_ExecutionSystem.cpp
+	intern/COM_ExecutionSystem.h
+	intern/COM_NodeConverter.cpp
+	intern/COM_NodeConverter.h
+	intern/COM_NodeOperationBuilder.cpp
+	intern/COM_NodeOperationBuilder.h
+	intern/COM_NodeGraph.cpp
+	intern/COM_NodeGraph.h
+	intern/COM_Converter.cpp
+	intern/COM_Converter.h
+	intern/COM_ExecutionGroup.cpp
+	intern/COM_ExecutionGroup.h
+	intern/COM_Node.cpp
+	intern/COM_Node.h
+	intern/COM_NodeOperation.cpp
+	intern/COM_NodeOperation.h
+	intern/COM_SocketReader.cpp
+	intern/COM_SocketReader.h
+	intern/COM_MemoryProxy.cpp
+	intern/COM_MemoryProxy.h
+	intern/COM_MemoryBuffer.cpp
+	intern/COM_MemoryBuffer.h
+	intern/COM_WorkScheduler.cpp
+	intern/COM_WorkScheduler.h
+	intern/COM_WorkPackage.cpp
+	intern/COM_WorkPackage.h
+	intern/COM_ChunkOrder.cpp
+	intern/COM_ChunkOrder.h
+	intern/COM_ChunkOrderHotspot.cpp
+	intern/COM_ChunkOrderHotspot.h
+	intern/COM_Device.cpp
+	intern/COM_Device.h
+	intern/COM_CPUDevice.cpp
+	intern/COM_CPUDevice.h
+	intern/COM_OpenCLDevice.cpp
+	intern/COM_OpenCLDevice.h
+	intern/COM_CompositorContext.cpp
+	intern/COM_CompositorContext.h
+	intern/COM_ChannelInfo.cpp
+	intern/COM_ChannelInfo.h
+	intern/COM_SingleThreadedOperation.cpp
+	intern/COM_SingleThreadedOperation.h
+	intern/COM_Debug.cpp
+	intern/COM_Debug.h
+
+	operations/COM_QualityStepHelper.h
+	operations/COM_QualityStepHelper.cpp
+
+	# Internal nodes
+	nodes/COM_SocketProxyNode.cpp
+	nodes/COM_SocketProxyNode.h
+
+	# input nodes
+	nodes/COM_RenderLayersNode.cpp
+	nodes/COM_RenderLayersNode.h
+	nodes/COM_ImageNode.cpp
+	nodes/COM_ImageNode.h
+	nodes/COM_TextureNode.cpp
+	nodes/COM_TextureNode.h
+	nodes/COM_BokehImageNode.cpp
+	nodes/COM_BokehImageNode.h
+	nodes/COM_ColorNode.cpp
+	nodes/COM_ColorNode.h
+	nodes/COM_ValueNode.cpp
+	nodes/COM_ValueNode.h
+	nodes/COM_TimeNode.cpp
+	nodes/COM_TimeNode.h
+	nodes/COM_SwitchNode.cpp
+	nodes/COM_SwitchNode.h
+	nodes/COM_MovieClipNode.cpp
+	nodes/COM_MovieClipNode.h
+	nodes/COM_OutputFileNode.cpp
+	nodes/COM_OutputFileNode.h
+	nodes/COM_MaskNode.cpp
+	nodes/COM_MaskNode.h
+
+	# output nodes
+	nodes/COM_CompositorNode.cpp
+	nodes/COM_CompositorNode.h
+	nodes/COM_ViewerNode.cpp
+	nodes/COM_ViewerNode.h
+	nodes/COM_SplitViewerNode.cpp
+	nodes/COM_SplitViewerNode.h
+	nodes/COM_ViewLevelsNode.cpp
+	nodes/COM_ViewLevelsNode.h
+	operations/COM_CalculateStandardDeviationOperation.cpp
+	operations/COM_CalculateStandardDeviationOperation.h
+	operations/COM_CalculateMeanOperation.cpp
+	operations/COM_CalculateMeanOperation.h
+
+	# distort nodes
+	nodes/COM_TranslateNode.cpp
+	nodes/COM_TranslateNode.h
+	nodes/COM_ScaleNode.cpp
+	nodes/COM_ScaleNode.h
+	nodes/COM_RotateNode.cpp
+	nodes/COM_RotateNode.h
+	nodes/COM_FlipNode.cpp
+	nodes/COM_FlipNode.h
+
+	nodes/COM_MapUVNode.cpp
+	nodes/COM_MapUVNode.h
+	nodes/COM_DisplaceNode.cpp
+	nodes/COM_DisplaceNode.h
+
+	nodes/COM_DifferenceMatteNode.cpp
+	nodes/COM_DifferenceMatteNode.h
+	nodes/COM_LuminanceMatteNode.cpp
+	nodes/COM_LuminanceMatteNode.h
+	nodes/COM_DistanceMatteNode.cpp
+	nodes/COM_DistanceMatteNode.h
+	nodes/COM_ChromaMatteNode.cpp
+	nodes/COM_ChromaMatteNode.h
+	nodes/COM_ColorMatteNode.cpp
+	nodes/COM_ColorMatteNode.h
+	nodes/COM_ChannelMatteNode.cpp
+	nodes/COM_ChannelMatteNode.h
+	nodes/COM_LensDistortionNode.cpp
+	nodes/COM_LensDistortionNode.h
+
+	nodes/COM_GlareNode.cpp
+	nodes/COM_GlareNode.h
+
+	nodes/COM_CornerPinNode.cpp
+	nodes/COM_CornerPinNode.h
+	nodes/COM_PlaneTrackDeformNode.cpp
+	nodes/COM_PlaneTrackDeformNode.h
+
+	nodes/COM_CropNode.cpp
+	nodes/COM_CropNode.h
+	operations/COM_CropOperation.cpp
+	operations/COM_CropOperation.h
+
+	nodes/COM_TransformNode.cpp
+	nodes/COM_TransformNode.h
+	nodes/COM_Stabilize2dNode.cpp
+	nodes/COM_Stabilize2dNode.h
+	nodes/COM_MovieDistortionNode.cpp
+	nodes/COM_MovieDistortionNode.h
+	nodes/COM_DefocusNode.cpp
+	nodes/COM_DefocusNode.h
+
+	# color nodes
+	nodes/COM_VectorCurveNode.cpp
+	nodes/COM_VectorCurveNode.h
+	nodes/COM_ColorCurveNode.cpp
+	nodes/COM_ColorCurveNode.h
+	nodes/COM_ColorToBWNode.cpp
+	nodes/COM_ColorToBWNode.h
+	nodes/COM_ColorRampNode.cpp
+	nodes/COM_ColorRampNode.h
+	nodes/COM_MixNode.cpp
+	nodes/COM_MixNode.h
+	nodes/COM_AlphaOverNode.cpp
+	nodes/COM_AlphaOverNode.h
+	nodes/COM_ZCombineNode.cpp
+	nodes/COM_ZCombineNode.h
+	nodes/COM_BrightnessNode.cpp
+	nodes/COM_BrightnessNode.h
+	nodes/COM_ColorBalanceNode.cpp
+	nodes/COM_ColorBalanceNode.h
+	nodes/COM_InvertNode.cpp
+	nodes/COM_InvertNode.h
+	nodes/COM_GammaNode.cpp
+	nodes/COM_GammaNode.h
+	nodes/COM_SetAlphaNode.cpp
+	nodes/COM_SetAlphaNode.h
+	nodes/COM_ConvertAlphaNode.cpp
+	nodes/COM_ConvertAlphaNode.h
+	nodes/COM_HueSaturationValueNode.cpp
+	nodes/COM_HueSaturationValueNode.h


@@ Diff output truncated at 10240 characters. @@




More information about the Bf-blender-cvs mailing list