[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [54241] trunk/blender/source/blender: style cleanup

Campbell Barton ideasman42 at gmail.com
Thu Jan 31 22:15:42 CET 2013


Revision: 54241
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=54241
Author:   campbellbarton
Date:     2013-01-31 21:15:38 +0000 (Thu, 31 Jan 2013)
Log Message:
-----------
style cleanup

Modified Paths:
--------------
    trunk/blender/source/blender/compositor/operations/COM_TranslateOperation.cpp
    trunk/blender/source/blender/editors/interface/interface_layout.c
    trunk/blender/source/blender/makesdna/DNA_node_types.h

Modified: trunk/blender/source/blender/compositor/operations/COM_TranslateOperation.cpp
===================================================================
--- trunk/blender/source/blender/compositor/operations/COM_TranslateOperation.cpp	2013-01-31 20:42:25 UTC (rev 54240)
+++ trunk/blender/source/blender/compositor/operations/COM_TranslateOperation.cpp	2013-01-31 21:15:38 UTC (rev 54241)
@@ -64,7 +64,7 @@
 	float originalXPos = x - this->getDeltaX();
 	float originalYPos = y - this->getDeltaY();
 
-	switch(m_wrappingType) {
+	switch (m_wrappingType) {
 		case 0:
 			//Intentionally empty, originalXPos and originalYPos have been set before
 			break;
@@ -83,7 +83,7 @@
 			break;
 	}
 
-	this->m_inputOperation->read(output, originalXPos , originalYPos, sampler);
+	this->m_inputOperation->read(output, originalXPos, originalYPos, sampler);
 
 }
 
@@ -98,20 +98,20 @@
 	newInput.ymin = input->ymin - this->getDeltaY();
 	newInput.ymax = input->ymax - this->getDeltaY();
 
-	if (m_wrappingType == 1 || m_wrappingType == 3){
+	if (m_wrappingType == 1 || m_wrappingType == 3) {
 		// wrap only on the x-axis if tile is wrapping
 		newInput.xmin = getWrappedOriginalXPos(input->xmin);
 		newInput.xmax = getWrappedOriginalXPos(input->xmax);
-		if(newInput.xmin > newInput.xmax){
+		if (newInput.xmin > newInput.xmax) {
 			newInput.xmin = 0;
 			newInput.xmax = this->getWidth();
 		}
 	}
-	if(m_wrappingType == 2 || m_wrappingType == 3) {
+	if (m_wrappingType == 2 || m_wrappingType == 3) {
 		// wrap only on the y-axis if tile is wrapping
 		newInput.ymin = getWrappedOriginalYPos(input->ymin);
 		newInput.ymax = getWrappedOriginalYPos(input->ymax);
-		if (newInput.ymin > newInput.ymax){
+		if (newInput.ymin > newInput.ymax) {
 			newInput.ymin = 0;
 			newInput.ymax = this->getHeight();
 		}
@@ -131,17 +131,22 @@
 	float originalXPos = 0;
 
 	// Positive offset: Append image data from the left
-	if ( this->m_relativeOffsetX > 0 ) {
-		if ( x < this->m_relativeOffsetX )
+	if (this->m_relativeOffsetX > 0) {
+		if (x < this->m_relativeOffsetX) {
 			originalXPos = this->getWidth() - this->m_relativeOffsetX + x;
-		else
-			originalXPos =  x - this->m_relativeOffsetX;
-	} else {
+		}
+		else {
+			originalXPos = x - this->m_relativeOffsetX;
+		}
+	}
+	else {
 		// Negative offset: Append image data from the right
-		if (x < (this->getWidth() + this->m_relativeOffsetX))
+		if (x < (this->getWidth() + this->m_relativeOffsetX)) {
 			originalXPos = x - this->m_relativeOffsetX;
-		else
+		}
+		else {
 			originalXPos = x - (this->getWidth() + this->m_relativeOffsetX);
+		}
 	}
 
 	while (originalXPos < 0) originalXPos += this->m_width;
@@ -154,17 +159,22 @@
 	float originalYPos = 0;
 
 	// Positive offset: Append image data from the bottom
-	if (  this->m_relativeOffsetY > 0 ) {
-		if ( y < this->m_relativeOffsetY )
-			originalYPos = this->getHeight()- this->m_relativeOffsetY + y;
-		else
-			originalYPos =  y - this->m_relativeOffsetY;
-	} else {
+	if (this->m_relativeOffsetY > 0) {
+		if (y < this->m_relativeOffsetY) {
+			originalYPos = this->getHeight() - this->m_relativeOffsetY + y;
+		}
+		else {
+			originalYPos = y - this->m_relativeOffsetY;
+		}
+	}
+	else {
 		// Negative offset: Append image data from the top
-		if (y < (this->getHeight() + this->m_relativeOffsetY))
+		if (y < (this->getHeight() + this->m_relativeOffsetY)) {
 			originalYPos = y - this->m_relativeOffsetY;
-		else
+		}
+		else {
 			originalYPos = y - (this->getHeight() + this->m_relativeOffsetY);
+		}
 	}
 
 	while (originalYPos < 0) originalYPos += this->m_height;

Modified: trunk/blender/source/blender/editors/interface/interface_layout.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface_layout.c	2013-01-31 20:42:25 UTC (rev 54240)
+++ trunk/blender/source/blender/editors/interface/interface_layout.c	2013-01-31 21:15:38 UTC (rev 54241)
@@ -1393,7 +1393,7 @@
 
 	/* turn button into search button */
 	if (searchprop) {
-		if(RNA_property_flag(prop) & PROP_NEVER_UNLINK)
+		if (RNA_property_flag(prop) & PROP_NEVER_UNLINK)
 			but->type = SEARCH_MENU;
 		else
 			but->type = SEARCH_MENU_UNLINK;

Modified: trunk/blender/source/blender/makesdna/DNA_node_types.h
===================================================================
--- trunk/blender/source/blender/makesdna/DNA_node_types.h	2013-01-31 20:42:25 UTC (rev 54240)
+++ trunk/blender/source/blender/makesdna/DNA_node_types.h	2013-01-31 21:15:38 UTC (rev 54241)
@@ -712,7 +712,7 @@
 } NodeTrackPosData;
 
 typedef struct NodeTranslateData {
-		char wrap_axis, pad[7];
+	char wrap_axis, pad[7];
 } NodeTranslateData;
 
 




More information about the Bf-blender-cvs mailing list