[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37200] trunk/blender/source/blender/ editors: compile without splash and icons when WITH_HEADLESS is set.

2011-06-05 Thread Campbell Barton
Revision: 37200
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37200
Author:   campbellbarton
Date: 2011-06-05 07:55:18 + (Sun, 05 Jun 2011)
Log Message:
---
compile without splash and icons when WITH_HEADLESS is set.

Modified Paths:
--
trunk/blender/source/blender/editors/datafiles/CMakeLists.txt
trunk/blender/source/blender/editors/interface/CMakeLists.txt
trunk/blender/source/blender/editors/interface/interface_draw.c
trunk/blender/source/blender/editors/interface/interface_icons.c
trunk/blender/source/blender/editors/space_file/CMakeLists.txt
trunk/blender/source/blender/editors/space_file/filelist.c

Modified: trunk/blender/source/blender/editors/datafiles/CMakeLists.txt
===
--- trunk/blender/source/blender/editors/datafiles/CMakeLists.txt   
2011-06-05 04:52:32 UTC (rev 37199)
+++ trunk/blender/source/blender/editors/datafiles/CMakeLists.txt   
2011-06-05 07:55:18 UTC (rev 37200)
@@ -29,41 +29,48 @@
 
 set(SRC
Bfont.c
-   add.png.c
bfont.ttf.c
-   blenderbuttons.c
-   blob.png.c
-   blur.png.c
bmonofont.ttf.c
-   clay.png.c
-   clone.png.c
-   crease.png.c
-   darken.png.c
-   draw.png.c
-   fill.png.c
-   flatten.png.c
-   grab.png.c
-   inflate.png.c
-   layer.png.c
-   lighten.png.c
-   mix.png.c
-   multiply.png.c
-   nudge.png.c
-   pinch.png.c
+   startup.blend.c
preview.blend.c
-   prvicons.c
-   scrape.png.c
-   smear.png.c
-   smooth.png.c
-   snake_hook.png.c
-   soften.png.c
-   splash.png.c
-   startup.blend.c
-   subtract.png.c
-   texdraw.png.c
-   thumb.png.c
-   twist.png.c
-   vertexdraw.png.c
 )
 
+if(NOT WITH_HEADLESS)
+   list(APPEND SRC
+   splash.png.c
+   blenderbuttons.c
+
+   # brushes
+   add.png.c
+   blob.png.c
+   blur.png.c
+   clay.png.c
+   clone.png.c
+   crease.png.c
+   darken.png.c
+   draw.png.c
+   fill.png.c
+   flatten.png.c
+   grab.png.c
+   inflate.png.c
+   layer.png.c
+   lighten.png.c
+   mix.png.c
+   multiply.png.c
+   nudge.png.c
+   pinch.png.c
+   prvicons.c
+   scrape.png.c
+   smear.png.c
+   smooth.png.c
+   snake_hook.png.c
+   soften.png.c
+   subtract.png.c
+   texdraw.png.c
+   thumb.png.c
+   twist.png.c
+   vertexdraw.png.c
+   )
+endif()
+
 blender_add_lib(bf_editor_datafiles ${SRC} ${INC} ${INC_SYS})

Modified: trunk/blender/source/blender/editors/interface/CMakeLists.txt
===
--- trunk/blender/source/blender/editors/interface/CMakeLists.txt   
2011-06-05 04:52:32 UTC (rev 37199)
+++ trunk/blender/source/blender/editors/interface/CMakeLists.txt   
2011-06-05 07:55:18 UTC (rev 37200)
@@ -63,6 +63,10 @@
add_definitions(-DINTERNATIONAL)
 endif()
 
+if(WITH_HEADLESS)
+   add_definitions(-DWITH_HEADLESS)
+endif()
+
 if(WITH_PYTHON)
add_definitions(-DWITH_PYTHON)
 endif()

Modified: trunk/blender/source/blender/editors/interface/interface_draw.c
===
--- trunk/blender/source/blender/editors/interface/interface_draw.c 
2011-06-05 04:52:32 UTC (rev 37199)
+++ trunk/blender/source/blender/editors/interface/interface_draw.c 
2011-06-05 07:55:18 UTC (rev 37200)
@@ -471,6 +471,9 @@
 
 void ui_draw_but_IMAGE(ARegion *UNUSED(ar), uiBut *UNUSED(but), uiWidgetColors 
*UNUSED(wcol), rcti *rect)
 {
+#ifdef WITH_HEADLESS
+   (void)rect;
+#else
extern char datatoc_splash_png[];
extern int datatoc_splash_png_size;
ImBuf *ibuf;
@@ -507,6 +510,7 @@
*/

IMB_freeImBuf(ibuf);
+#endif
 }
 
 #if 0

Modified: trunk/blender/source/blender/editors/interface/interface_icons.c
===
--- trunk/blender/source/blender/editors/interface/interface_icons.c
2011-06-05 04:52:32 UTC (rev 37199)
+++ trunk/blender/source/blender/editors/interface/interface_icons.c
2011-06-05 07:55:18 UTC (rev 37200)
@@ -461,6 +461,7 @@
glDisable(GL_LINE_SMOOTH);
 }
 
+#ifndef WITH_HEADLESS
 static void init_brush_icons(void)
 {
 
@@ -588,8 +589,8 @@
 
IMB_freeImBuf(bbuf);
 }
+#endif // WITH_HEADLESS
 
-
 static void init_iconfile_list(struct ListBase *list)
 {
IconFile *ifile;
@@ -704,6 +705,7 @@
 
 void UI_icons_free(void)
 {
+#ifndef WITH_HEADLESS
if(icongltex.id) {
   

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37201] trunk/blender/source/blender/ python/intern/bpy_driver.c: py/drivers disable dont interning strings, no need really since this isnt done on ev

2011-06-05 Thread Campbell Barton
Revision: 37201
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37201
Author:   campbellbarton
Date: 2011-06-05 08:18:37 + (Sun, 05 Jun 2011)
Log Message:
---
py/drivers disable dont interning strings, no need really since this isnt done 
on every execution.

Modified Paths:
--
trunk/blender/source/blender/python/intern/bpy_driver.c

Modified: trunk/blender/source/blender/python/intern/bpy_driver.c
===
--- trunk/blender/source/blender/python/intern/bpy_driver.c 2011-06-05 
07:55:18 UTC (rev 37200)
+++ trunk/blender/source/blender/python/intern/bpy_driver.c 2011-06-05 
08:18:37 UTC (rev 37201)
@@ -190,7 +190,7 @@
PyTuple_SET_ITEM(((PyObject *)driver-expr_comp), 1, expr_vars);
 
for (dvar= driver-variables.first, i=0; dvar; dvar= 
dvar-next) {
-   PyTuple_SET_ITEM(expr_vars, i++, 
PyUnicode_InternFromString(dvar-name));
+   PyTuple_SET_ITEM(expr_vars, i++, 
PyUnicode_FromString(dvar-name));
}

driver-flag = ~DRIVER_FLAG_RENAMEVAR;

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37202] trunk/blender/source/blender: with the new scalable UI.

2011-06-05 Thread Campbell Barton
Revision: 37202
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37202
Author:   campbellbarton
Date: 2011-06-05 09:00:36 + (Sun, 05 Jun 2011)
Log Message:
---
with the new scalable UI. hard coded values were still used for resizing the 
headers, with DPI of 56 the headers could not be un-hidden.

Modified Paths:
--
trunk/blender/source/blender/blenloader/intern/readfile.c
trunk/blender/source/blender/editors/screen/screen_ops.c

Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===
--- trunk/blender/source/blender/blenloader/intern/readfile.c   2011-06-05 
08:18:37 UTC (rev 37201)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c   2011-06-05 
09:00:36 UTC (rev 37202)
@@ -6280,7 +6280,7 @@

BLI_addtail(lb, ar);
ar-regiontype= RGN_TYPE_HEADER;
-   if(sa-headertype==1)
+   if(sa-headertype==HEADERDOWN)
ar-alignment= RGN_ALIGN_BOTTOM;
else
ar-alignment= RGN_ALIGN_TOP;

Modified: trunk/blender/source/blender/editors/screen/screen_ops.c
===
--- trunk/blender/source/blender/editors/screen/screen_ops.c2011-06-05 
08:18:37 UTC (rev 37201)
+++ trunk/blender/source/blender/editors/screen/screen_ops.c2011-06-05 
09:00:36 UTC (rev 37202)
@@ -1631,7 +1631,7 @@
rmd-ar-sizex= rmd-origval + delta;
CLAMP(rmd-ar-sizex, 0, rmd-maxsize);

-   if(rmd-ar-sizex  24) {
+   if(rmd-ar-sizex  UI_UNIT_X) {
rmd-ar-sizex= rmd-origval;
if(!(rmd-ar-flag  RGN_FLAG_HIDDEN))
ED_region_toggle_hidden(C, 
rmd-ar);
@@ -1646,11 +1646,17 @@

rmd-ar-sizey= rmd-origval + delta;
CLAMP(rmd-ar-sizey, 0, rmd-maxsize);
-   
-   if(rmd-ar-regiontype == RGN_TYPE_TOOL_PROPS)
-   maxsize = rmd-maxsize - 
((rmd-sa-headertype==2)?48:24) - 10;
 
-   if(rmd-ar-sizey  24 || (maxsize  0  
(rmd-ar-sizey  maxsize)) ) {
+   if(rmd-ar-regiontype == RGN_TYPE_TOOL_PROPS) {
+   /* this calculation seems overly verbose
+* can someone explain why this method 
is necessary? - campbell */
+   maxsize = rmd-maxsize - 
((rmd-sa-headertype==HEADERTOP)?UI_UNIT_Y*2:UI_UNIT_Y) - (UI_UNIT_Y/4);
+   }
+
+   /* note, 'UI_UNIT_Y/4' means you need to drag 
the header almost
+* all the way down for it to become hidden, 
this is done
+* otherwise its too easy to do this by 
accident */
+   if(rmd-ar-sizey  UI_UNIT_Y/4 || (maxsize  0 
 (rmd-ar-sizey  maxsize)) ) {
rmd-ar-sizey= rmd-origval;
if(!(rmd-ar-flag  RGN_FLAG_HIDDEN))
ED_region_toggle_hidden(C, 
rmd-ar);

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37203] trunk/blender/source/blender/ editors/screen/area.c: workaround for supremely annoying UI glitch where you could accidentally hide the file se

2011-06-05 Thread Campbell Barton
Revision: 37203
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37203
Author:   campbellbarton
Date: 2011-06-05 09:22:14 + (Sun, 05 Jun 2011)
Log Message:
---
workaround for supremely annoying UI glitch where you could accidentally hide 
the file selector header by accident.
using the logic - that a header taking up the full screen-area height will not 
have an action-zone added for resizing.

Modified Paths:
--
trunk/blender/source/blender/editors/screen/area.c

Modified: trunk/blender/source/blender/editors/screen/area.c
===
--- trunk/blender/source/blender/editors/screen/area.c  2011-06-05 09:00:36 UTC 
(rev 37202)
+++ trunk/blender/source/blender/editors/screen/area.c  2011-06-05 09:22:14 UTC 
(rev 37203)
@@ -815,9 +815,19 @@
ar-winrct.xmax= ar-winrct.xmin;
}
/* in end, add azones, where appropriate */
-   region_azone_add(sa, ar, alignment);
+   if(ar-regiontype == RGN_TYPE_HEADER  ar-winy + 6  sa-winy) {
+   /* The logic for this is: when the header takes up the full 
area,
+* disallow hiding it to view the main window.
+*
+* Without this, uou can drag down the file selectors header 
and hide it
+* by accident very easily (highly annoying!), the value 6 is 
arbitrary
+* but accounts for small common rounding problems when scaling 
the UI,
+* must be minimum '4' */
+   }
+   else {
+   region_azone_add(sa, ar, alignment);
+   }
 
-
region_rect_recursive(sa, ar-next, remainder, quad);
 }
 

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37204] trunk/blender/source/blender/ editors/space_file: scale the file selector UI with the DPI, the region size can still be wrong though.

2011-06-05 Thread Campbell Barton
Revision: 37204
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37204
Author:   campbellbarton
Date: 2011-06-05 10:05:13 + (Sun, 05 Jun 2011)
Log Message:
---
scale the file selector UI with the DPI, the region size can still be wrong 
though.

Modified Paths:
--
trunk/blender/source/blender/editors/space_file/file_draw.c
trunk/blender/source/blender/editors/space_file/file_intern.h

Modified: trunk/blender/source/blender/editors/space_file/file_draw.c
===
--- trunk/blender/source/blender/editors/space_file/file_draw.c 2011-06-05 
09:22:14 UTC (rev 37203)
+++ trunk/blender/source/blender/editors/space_file/file_draw.c 2011-06-05 
10:05:13 UTC (rev 37204)
@@ -74,12 +74,6 @@
 
 #include file_intern.h   // own include
 
-/* ui geometry */
-#define IMASEL_BUTTONS_HEIGHT 40
-#define IMASEL_BUTTONS_MARGIN 6
-#define TILE_BORDER_X 8
-#define TILE_BORDER_Y 8
-
 /* button events */
 enum {
B_FS_DIRNAME,

Modified: trunk/blender/source/blender/editors/space_file/file_intern.h
===
--- trunk/blender/source/blender/editors/space_file/file_intern.h   
2011-06-05 09:22:14 UTC (rev 37203)
+++ trunk/blender/source/blender/editors/space_file/file_intern.h   
2011-06-05 10:05:13 UTC (rev 37204)
@@ -43,9 +43,13 @@
 struct ARegion *file_buttons_region(struct ScrArea *sa);
 
 /* file_draw.c */
-#define TILE_BORDER_X 8
-#define TILE_BORDER_Y 8
+#define TILE_BORDER_X (UI_UNIT_X/4)
+#define TILE_BORDER_Y (UI_UNIT_Y/4)
 
+/* ui geometry */
+#define IMASEL_BUTTONS_HEIGHT (UI_UNIT_Y*2)
+#define IMASEL_BUTTONS_MARGIN (UI_UNIT_Y/6)
+
 void file_draw_buttons(const bContext *C, ARegion *ar);
 void file_calc_previews(const bContext *C, ARegion *ar);
 void file_draw_previews(const bContext *C, ARegion *ar);

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37205] trunk/blender/source/blender: panel headers were not scaling with DPI properly

2011-06-05 Thread Campbell Barton
Revision: 37205
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37205
Author:   campbellbarton
Date: 2011-06-05 12:47:17 + (Sun, 05 Jun 2011)
Log Message:
---
panel headers were not scaling with DPI properly

Modified Paths:
--
trunk/blender/source/blender/editors/interface/interface_intern.h
trunk/blender/source/blender/editors/interface/interface_panel.c
trunk/blender/source/blender/editors/screen/area.c
trunk/blender/source/blender/python/intern/bpy_driver.c

Modified: trunk/blender/source/blender/editors/interface/interface_intern.h
===
--- trunk/blender/source/blender/editors/interface/interface_intern.h   
2011-06-05 10:05:13 UTC (rev 37204)
+++ trunk/blender/source/blender/editors/interface/interface_intern.h   
2011-06-05 12:47:17 UTC (rev 37205)
@@ -117,8 +117,8 @@
 /* warn: rest of uiBut-flag in UI_interface.h */
 
 /* internal panel drawing defines */
-#define PNL_GRID   4
-#define PNL_HEADER  20
+#define PNL_GRID   (UI_UNIT_Y / 5) /* 4 default */
+#define PNL_HEADER  UI_UNIT_Y  /* 20 default */
 
 /* panel-flag */
 #define PNL_SELECT 1

Modified: trunk/blender/source/blender/editors/interface/interface_panel.c
===
--- trunk/blender/source/blender/editors/interface/interface_panel.c
2011-06-05 10:05:13 UTC (rev 37204)
+++ trunk/blender/source/blender/editors/interface/interface_panel.c
2011-06-05 12:47:17 UTC (rev 37205)
@@ -384,7 +384,7 @@
 
 }
 
-#define PNL_ICON   20
+#define PNL_ICON   UI_UNIT_X  /* could be UI_UNIT_Y too */
 
 static void ui_draw_panel_scalewidget(rcti *rect)
 {

Modified: trunk/blender/source/blender/editors/screen/area.c
===
--- trunk/blender/source/blender/editors/screen/area.c  2011-06-05 10:05:13 UTC 
(rev 37204)
+++ trunk/blender/source/blender/editors/screen/area.c  2011-06-05 12:47:17 UTC 
(rev 37205)
@@ -1281,11 +1281,11 @@
 
if(vertical) {
w= v2d-cur.xmax - v2d-cur.xmin;
-   em= (ar-type-prefsizex)? 10: 20;
+   em= (ar-type-prefsizex)? UI_UNIT_Y/2: UI_UNIT_Y;
}
else {
w= UI_PANEL_WIDTH;
-   em= (ar-type-prefsizex)? 10: 20;
+   em= (ar-type-prefsizex)? UI_UNIT_Y/2: UI_UNIT_Y;
}
 
x= 0;
@@ -1309,8 +1309,8 @@
panel= uiBeginPanel(sa, ar, block, pt, open);
 
/* bad fixed values */
-   header= (pt-flag  PNL_NO_HEADER)? 0: 20;
-   triangle= 22;
+   header= (pt-flag  PNL_NO_HEADER)? 0: UI_UNIT_Y;
+   triangle= (int)(UI_UNIT_Y * 1.1f);
 
if(vertical)
y -= header;

Modified: trunk/blender/source/blender/python/intern/bpy_driver.c
===
--- trunk/blender/source/blender/python/intern/bpy_driver.c 2011-06-05 
10:05:13 UTC (rev 37204)
+++ trunk/blender/source/blender/python/intern/bpy_driver.c 2011-06-05 
12:47:17 UTC (rev 37205)
@@ -185,7 +185,6 @@
expr_vars= PyTuple_GET_ITEM(((PyObject *)driver-expr_comp), 1);
Py_XDECREF(expr_vars);
 
-   /* intern the arg names so creating the namespace for every run 
is faster */
expr_vars= PyTuple_New(BLI_countlist(driver-variables));
PyTuple_SET_ITEM(((PyObject *)driver-expr_comp), 1, expr_vars);
 
@@ -211,7 +210,7 @@

/* try to add to dictionary */
/* if (PyDict_SetItemString(driver_vars, dvar-name, 
driver_arg)) { */
-   if (PyDict_SetItem(driver_vars, PyTuple_GET_ITEM(expr_vars, 
i++), driver_arg)  0) { /* use string interning for faster namespace creation 
*/
+   if (PyDict_SetItem(driver_vars, PyTuple_GET_ITEM(expr_vars, 
i++), driver_arg)  0) {
/* this target failed - bad name */
if (targets_ok) {
/* first one - print some extra info for easier 
identification */

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37206] trunk/blender/source/blender/ editors: Bugfix: new DPI-controlled UI size code was setting ' view2d re-init'

2011-06-05 Thread Ton Roosendaal
Revision: 37206
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37206
Author:   ton
Date: 2011-06-05 12:57:09 + (Sun, 05 Jun 2011)
Log Message:
---
Bugfix: new DPI-controlled UI size code was setting 'view2d re-init'
flag on ED_area_initialize(). This however was causing 2 problems;
- the view state got reset (popping window view back)
- the view2d operator polls failed (sliders didnt work)

This re-init was only needed for the headers though, limiting it
to these types of regions solves it.

Modified Paths:
--
trunk/blender/source/blender/editors/screen/area.c
trunk/blender/source/blender/editors/space_api/spacetypes.c

Modified: trunk/blender/source/blender/editors/screen/area.c
===
--- trunk/blender/source/blender/editors/screen/area.c  2011-06-05 12:47:17 UTC 
(rev 37205)
+++ trunk/blender/source/blender/editors/screen/area.c  2011-06-05 12:57:09 UTC 
(rev 37206)
@@ -967,8 +967,9 @@
uiFreeBlocks(NULL, ar-uiblocks);  
}

-   /* rechecks all 2d matrices */
-   ar-v2d.flag = ~V2D_IS_INITIALISED;
+   /* rechecks 2d matrix for header on dpi changing, do not do for 
other regions, it resets view  blocks view2d operator polls (ton) */
+   if(ar-regiontype==RGN_TYPE_HEADER)
+   ar-v2d.flag = ~V2D_IS_INITIALISED;
}
 }
 

Modified: trunk/blender/source/blender/editors/space_api/spacetypes.c
===
--- trunk/blender/source/blender/editors/space_api/spacetypes.c 2011-06-05 
12:47:17 UTC (rev 37205)
+++ trunk/blender/source/blender/editors/space_api/spacetypes.c 2011-06-05 
12:57:09 UTC (rev 37206)
@@ -70,6 +70,9 @@
const ListBase *spacetypes;
SpaceType *type;
 
+   /* UI_UNIT_X is now a variable, is used in some spacetype inits? */
+   U.widget_unit= 20;
+   
/* create space types */
ED_spacetype_outliner();
ED_spacetype_time();

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37207] trunk/blender/source/blender/ editors: colorband and image header were ignoring DPI size

2011-06-05 Thread Campbell Barton
Revision: 37207
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37207
Author:   campbellbarton
Date: 2011-06-05 13:20:30 + (Sun, 05 Jun 2011)
Log Message:
---
colorband and image header were ignoring DPI size

Modified Paths:
--
trunk/blender/source/blender/editors/interface/interface_templates.c
trunk/blender/source/blender/editors/space_image/image_buttons.c

Modified: trunk/blender/source/blender/editors/interface/interface_templates.c
===
--- trunk/blender/source/blender/editors/interface/interface_templates.c
2011-06-05 12:57:09 UTC (rev 37206)
+++ trunk/blender/source/blender/editors/interface/interface_templates.c
2011-06-05 13:20:30 UTC (rev 37207)
@@ -1281,31 +1281,32 @@
 /* offset aligns from bottom, standard width 300, height 115 */
 static void colorband_buttons_large(uiLayout *layout, uiBlock *block, 
ColorBand *coba, int xoffs, int yoffs, RNAUpdateCb *cb)
 {
-   
uiBut *bt;
uiLayout *row;
+   const int line1_y= yoffs + 65 + UI_UNIT_Y + 2; /* 2 for some space 
between the buttons */
+   const int line2_y= yoffs + 65;
 
if(coba==NULL) return;
 
-   bt= uiDefBut(block, BUT, 0, Add,  
0+xoffs,100+yoffs,40,20, NULL, 0, 0, 0, 0, Add a new color stop to the 
colorband);
+   bt= uiDefBut(block, BUT, 0, Add,  
0+xoffs,line1_y,40,UI_UNIT_Y, NULL, 0, 0, 0, 0, Add a new color stop to the 
colorband);
uiButSetNFunc(bt, colorband_add_cb, MEM_dupallocN(cb), coba);
 
-   bt= uiDefBut(block, BUT, 0, Delete,   
45+xoffs,100+yoffs,45,20, NULL, 0, 0, 0, 0, Delete the active position);
+   bt= uiDefBut(block, BUT, 0, Delete,   
45+xoffs,line1_y,45,UI_UNIT_Y, NULL, 0, 0, 0, 0, Delete the active position);
uiButSetNFunc(bt, colorband_del_cb, MEM_dupallocN(cb), coba);
 
 
/* XXX, todo for later - convert to operator - campbell */
-   bt= uiDefBut(block, BUT, 0, F,
95+xoffs,100+yoffs,20,20, NULL, 0, 0, 0, 0, Flip colorband);
+   bt= uiDefBut(block, BUT, 0, F,
95+xoffs,line1_y,20,UI_UNIT_Y, NULL, 0, 0, 0, 0, Flip colorband);
uiButSetNFunc(bt, colorband_flip_cb, MEM_dupallocN(cb), coba);
 
-   uiDefButS(block, NUM, 0,, 
120+xoffs,100+yoffs,80, 20, coba-cur, 0.0, (float)(MAX2(0, coba-tot-1)), 0, 
0, Choose active color stop);
+   uiDefButS(block, NUM, 0,, 
120+xoffs,line1_y,80, UI_UNIT_Y, coba-cur, 0.0, (float)(MAX2(0, 
coba-tot-1)), 0, 0, Choose active color stop);
 
bt= uiDefButS(block, MENU, 0,   Interpolation %t|Ease 
%x1|Cardinal %x3|Linear %x0|B-Spline %x2|Constant %x4,
-   210+xoffs, 100+yoffs, 90, 20,   coba-ipotype, 
0.0, 0.0, 0, 0, Set interpolation between color stops);
+   210+xoffs, line1_y, 90, UI_UNIT_Y,  
coba-ipotype, 0.0, 0.0, 0, 0, Set interpolation between color stops);
uiButSetNFunc(bt, rna_update_cb, MEM_dupallocN(cb), NULL);
uiBlockEndAlign(block);
 
-   bt= uiDefBut(block, BUT_COLORBAND, 0, ,   xoffs,65+yoffs,300,30, 
coba, 0, 0, 0, 0, );
+   bt= uiDefBut(block, BUT_COLORBAND, 0, ,   
xoffs,line2_y,300,UI_UNIT_Y, coba, 0, 0, 0, 0, );
uiButSetNFunc(bt, rna_update_cb, MEM_dupallocN(cb), NULL);
 
 
@@ -1330,11 +1331,11 @@
float xs= butr-xmin;
 
uiBlockBeginAlign(block);
-   bt= uiDefBut(block, BUT, 0, Add,  
xs,butr-ymin+20.0f,2.0f*unit,20,   NULL, 0, 0, 0, 0, Add a new color stop 
to the colorband);
+   bt= uiDefBut(block, BUT, 0, Add,  
xs,butr-ymin+UI_UNIT_Y,2.0f*unit,UI_UNIT_Y,NULL, 0, 0, 0, 0, Add a new 
color stop to the colorband);
uiButSetNFunc(bt, colorband_add_cb, MEM_dupallocN(cb), coba);
-   bt= uiDefBut(block, BUT, 0, Delete,   
xs+2.0f*unit,butr-ymin+20.0f,1.5f*unit,20, NULL, 0, 0, 0, 0, Delete the 
active position);
+   bt= uiDefBut(block, BUT, 0, Delete,   
xs+2.0f*unit,butr-ymin+UI_UNIT_Y,1.5f*unit,UI_UNIT_Y,  NULL, 0, 0, 0, 0, 
Delete the active position);
uiButSetNFunc(bt, colorband_del_cb, MEM_dupallocN(cb), coba);
-   bt= uiDefBut(block, BUT, 0, F,
xs+3.5f*unit,butr-ymin+20.0f,0.5f*unit,20, NULL, 0, 0, 0, 0, Flip the 
color ramp);
+   bt= uiDefBut(block, BUT, 0, F,
xs+3.5f*unit,butr-ymin+UI_UNIT_Y,0.5f*unit,UI_UNIT_Y,  NULL, 0, 0, 0, 0, Flip 
the color ramp);
uiButSetNFunc(bt, colorband_flip_cb, MEM_dupallocN(cb), coba);
uiBlockEndAlign(block);
 
@@ -1346,10 +1347,10 @@
}
 
bt= uiDefButS(block, MENU, 0,   Interpolation %t|Ease 
%x1|Cardinal %x3|Linear %x0|B-Spline %x2|Constant %x4,
-   

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37208] branches/soc-2011-onion: Merged with trunk: 37055-37206

2011-06-05 Thread Jason Wilkins
Revision: 37208
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37208
Author:   jwilkins
Date: 2011-06-05 13:44:55 + (Sun, 05 Jun 2011)
Log Message:
---
Merged with trunk: 37055-37206

Modified Paths:
--
branches/soc-2011-onion/CMakeLists.txt
branches/soc-2011-onion/build_files/buildbot/master.cfg
branches/soc-2011-onion/build_files/buildbot/master_unpack.py
branches/soc-2011-onion/build_files/buildbot/slave_compile.py
branches/soc-2011-onion/build_files/buildbot/slave_pack.py
branches/soc-2011-onion/build_files/scons/tools/btools.py
branches/soc-2011-onion/doc/manpage/blender.1
branches/soc-2011-onion/extern/glew/include/GL/glew.h
branches/soc-2011-onion/extern/glew/include/GL/glxew.h
branches/soc-2011-onion/extern/glew/include/GL/wglew.h
branches/soc-2011-onion/extern/glew/src/glew.c
branches/soc-2011-onion/intern/ghost/CMakeLists.txt
branches/soc-2011-onion/intern/ghost/intern/GHOST_ISystem.cpp
branches/soc-2011-onion/intern/ghost/intern/GHOST_NDOFManager.cpp
branches/soc-2011-onion/release/scripts/modules/bpy_extras/io_utils.py

branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_curve.py

branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_mesh.py

branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_metaball.py
branches/soc-2011-onion/release/scripts/startup/bl_ui/space_userpref.py

branches/soc-2011-onion/release/scripts/startup/bl_ui/space_userpref_keymap.py
branches/soc-2011-onion/release/scripts/startup/bl_ui/space_view3d.py
branches/soc-2011-onion/release/windows/installer/00.sconsblender.nsi
branches/soc-2011-onion/source/blender/blenkernel/BKE_blender.h
branches/soc-2011-onion/source/blender/blenkernel/BKE_global.h
branches/soc-2011-onion/source/blender/blenkernel/BKE_texture.h
branches/soc-2011-onion/source/blender/blenkernel/intern/blender.c
branches/soc-2011-onion/source/blender/blenkernel/intern/multires.c
branches/soc-2011-onion/source/blender/blenkernel/intern/node.c
branches/soc-2011-onion/source/blender/blenkernel/intern/particle.c
branches/soc-2011-onion/source/blender/blenkernel/intern/seqeffects.c
branches/soc-2011-onion/source/blender/blenkernel/intern/sequencer.c
branches/soc-2011-onion/source/blender/blenkernel/intern/texture.c
branches/soc-2011-onion/source/blender/blenlib/intern/path_util.c
branches/soc-2011-onion/source/blender/blenloader/intern/readfile.c
branches/soc-2011-onion/source/blender/blenloader/intern/writefile.c
branches/soc-2011-onion/source/blender/editors/datafiles/CMakeLists.txt
branches/soc-2011-onion/source/blender/editors/include/ED_particle.h
branches/soc-2011-onion/source/blender/editors/include/ED_screen.h
branches/soc-2011-onion/source/blender/editors/include/ED_types.h
branches/soc-2011-onion/source/blender/editors/include/ED_util.h
branches/soc-2011-onion/source/blender/editors/include/UI_interface.h
branches/soc-2011-onion/source/blender/editors/interface/CMakeLists.txt
branches/soc-2011-onion/source/blender/editors/interface/interface.c
branches/soc-2011-onion/source/blender/editors/interface/interface_draw.c

branches/soc-2011-onion/source/blender/editors/interface/interface_handlers.c
branches/soc-2011-onion/source/blender/editors/interface/interface_icons.c
branches/soc-2011-onion/source/blender/editors/interface/interface_intern.h
branches/soc-2011-onion/source/blender/editors/interface/interface_panel.c
branches/soc-2011-onion/source/blender/editors/interface/interface_regions.c

branches/soc-2011-onion/source/blender/editors/interface/interface_templates.c
branches/soc-2011-onion/source/blender/editors/interface/interface_widgets.c
branches/soc-2011-onion/source/blender/editors/interface/resources.c
branches/soc-2011-onion/source/blender/editors/object/object_add.c
branches/soc-2011-onion/source/blender/editors/physics/particle_edit.c
branches/soc-2011-onion/source/blender/editors/screen/area.c
branches/soc-2011-onion/source/blender/editors/screen/screen_edit.c
branches/soc-2011-onion/source/blender/editors/screen/screen_ops.c
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_vertex.c
branches/soc-2011-onion/source/blender/editors/space_action/space_action.c
branches/soc-2011-onion/source/blender/editors/space_api/spacetypes.c

branches/soc-2011-onion/source/blender/editors/space_buttons/buttons_header.c
branches/soc-2011-onion/source/blender/editors/space_file/CMakeLists.txt
branches/soc-2011-onion/source/blender/editors/space_file/file_draw.c
branches/soc-2011-onion/source/blender/editors/space_file/file_intern.h
branches/soc-2011-onion/source/blender/editors/space_file/filelist.c
branches/soc-2011-onion/source/blender/editors/space_node/space_node.c

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37209] branches/soc-2011-salad: Merged with trunk: 37150-37206 (command line and output follows)

2011-06-05 Thread Jason Wilkins
Revision: 37209
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37209
Author:   jwilkins
Date: 2011-06-05 13:59:04 + (Sun, 05 Jun 2011)
Log Message:
---
Merged with trunk: 37150-37206 (command line and output follows)

D:\gsoc\soc-2011-saladsvn merge 
^https://svn.blender.org/svnroot/bf-blender/trunk/blender@37206 
--non-interactive
--- Merging r37150 through r37206 into '.':
...

Revision Links:
--

http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37150

http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37206

Modified Paths:
--
branches/soc-2011-salad/CMakeLists.txt
branches/soc-2011-salad/doc/manpage/blender.1
branches/soc-2011-salad/intern/ghost/CMakeLists.txt
branches/soc-2011-salad/intern/ghost/intern/GHOST_ISystem.cpp
branches/soc-2011-salad/intern/ghost/intern/GHOST_NDOFManager.cpp

branches/soc-2011-salad/release/scripts/startup/bl_ui/properties_data_curve.py

branches/soc-2011-salad/release/scripts/startup/bl_ui/properties_data_mesh.py

branches/soc-2011-salad/release/scripts/startup/bl_ui/properties_data_metaball.py
branches/soc-2011-salad/release/scripts/startup/bl_ui/space_view3d.py
branches/soc-2011-salad/source/blender/blenkernel/BKE_blender.h
branches/soc-2011-salad/source/blender/blenkernel/intern/blender.c
branches/soc-2011-salad/source/blender/blenkernel/intern/seqeffects.c
branches/soc-2011-salad/source/blender/blenkernel/intern/sequencer.c
branches/soc-2011-salad/source/blender/blenlib/intern/path_util.c
branches/soc-2011-salad/source/blender/blenloader/intern/readfile.c
branches/soc-2011-salad/source/blender/editors/datafiles/CMakeLists.txt
branches/soc-2011-salad/source/blender/editors/include/ED_particle.h
branches/soc-2011-salad/source/blender/editors/include/ED_screen.h
branches/soc-2011-salad/source/blender/editors/include/ED_types.h
branches/soc-2011-salad/source/blender/editors/include/ED_util.h
branches/soc-2011-salad/source/blender/editors/include/UI_interface.h
branches/soc-2011-salad/source/blender/editors/interface/CMakeLists.txt
branches/soc-2011-salad/source/blender/editors/interface/interface.c
branches/soc-2011-salad/source/blender/editors/interface/interface_draw.c

branches/soc-2011-salad/source/blender/editors/interface/interface_handlers.c
branches/soc-2011-salad/source/blender/editors/interface/interface_icons.c
branches/soc-2011-salad/source/blender/editors/interface/interface_intern.h
branches/soc-2011-salad/source/blender/editors/interface/interface_panel.c
branches/soc-2011-salad/source/blender/editors/interface/interface_regions.c

branches/soc-2011-salad/source/blender/editors/interface/interface_templates.c
branches/soc-2011-salad/source/blender/editors/interface/interface_widgets.c
branches/soc-2011-salad/source/blender/editors/interface/resources.c
branches/soc-2011-salad/source/blender/editors/object/object_add.c
branches/soc-2011-salad/source/blender/editors/physics/particle_edit.c
branches/soc-2011-salad/source/blender/editors/screen/area.c
branches/soc-2011-salad/source/blender/editors/screen/screen_edit.c
branches/soc-2011-salad/source/blender/editors/screen/screen_ops.c
branches/soc-2011-salad/source/blender/editors/space_action/space_action.c
branches/soc-2011-salad/source/blender/editors/space_api/spacetypes.c

branches/soc-2011-salad/source/blender/editors/space_buttons/buttons_header.c
branches/soc-2011-salad/source/blender/editors/space_file/CMakeLists.txt
branches/soc-2011-salad/source/blender/editors/space_file/file_draw.c
branches/soc-2011-salad/source/blender/editors/space_file/file_intern.h
branches/soc-2011-salad/source/blender/editors/space_file/filelist.c
branches/soc-2011-salad/source/blender/editors/space_script/script_header.c
branches/soc-2011-salad/source/blender/editors/space_sound/sound_header.c
branches/soc-2011-salad/source/blender/editors/space_view3d/view3d_header.c
branches/soc-2011-salad/source/blender/editors/util/editmode_undo.c
branches/soc-2011-salad/source/blender/editors/util/undo.c
branches/soc-2011-salad/source/blender/editors/util/util_intern.h
branches/soc-2011-salad/source/blender/imbuf/intern/targa.c
branches/soc-2011-salad/source/blender/makesdna/DNA_screen_types.h
branches/soc-2011-salad/source/blender/makesdna/DNA_userdef_types.h
branches/soc-2011-salad/source/blender/makesrna/intern/rna_object.c
branches/soc-2011-salad/source/blender/makesrna/intern/rna_userdef.c
branches/soc-2011-salad/source/blender/modifiers/CMakeLists.txt
branches/soc-2011-salad/source/blender/modifiers/intern/MOD_none.c
branches/soc-2011-salad/source/blender/python/intern/bpy_driver.c
branches/soc-2011-salad/source/blender/windowmanager/CMakeLists.txt

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37210] trunk/blender/source/blender/ editors: file selector now scales with DPI better

2011-06-05 Thread Campbell Barton
Revision: 37210
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37210
Author:   campbellbarton
Date: 2011-06-05 14:00:06 + (Sun, 05 Jun 2011)
Log Message:
---
file selector now scales with DPI better

Modified Paths:
--
trunk/blender/source/blender/editors/include/UI_interface_icons.h
trunk/blender/source/blender/editors/space_file/file_draw.c
trunk/blender/source/blender/editors/space_file/filesel.c

Modified: trunk/blender/source/blender/editors/include/UI_interface_icons.h
===
--- trunk/blender/source/blender/editors/include/UI_interface_icons.h   
2011-06-05 13:59:04 UTC (rev 37209)
+++ trunk/blender/source/blender/editors/include/UI_interface_icons.h   
2011-06-05 14:00:06 UTC (rev 37210)
@@ -49,6 +49,10 @@
 
 #define ICON_DEFAULT_HEIGHT 16
 #define ICON_DEFAULT_WIDTH 16
+
+#define ICON_DEFAULT_HEIGHT_SCALE  (UI_UNIT_Y * 0.8f)
+#define ICON_DEFAULT_WIDTH_SCALE   (UI_UNIT_X * 0.8f)
+
 #define PREVIEW_DEFAULT_HEIGHT 96
 
 /*

Modified: trunk/blender/source/blender/editors/space_file/file_draw.c
===
--- trunk/blender/source/blender/editors/space_file/file_draw.c 2011-06-05 
13:59:04 UTC (rev 37209)
+++ trunk/blender/source/blender/editors/space_file/file_draw.c 2011-06-05 
14:00:06 UTC (rev 37210)
@@ -517,8 +517,8 @@

file_draw_preview(block, file, sx, sy, imb, layout, 
!is_icon  (file-flags  IMAGEFILE));
} else {
-   file_draw_icon(block, file-path, sx, sy-3, 
get_file_icon(file), ICON_DEFAULT_WIDTH, ICON_DEFAULT_WIDTH);
-   sx += ICON_DEFAULT_WIDTH + 4;
+   file_draw_icon(block, file-path, sx, sy-(UI_UNIT_Y / 
6), get_file_icon(file), ICON_DEFAULT_WIDTH_SCALE, ICON_DEFAULT_WIDTH_SCALE);
+   sx += ICON_DEFAULT_WIDTH_SCALE + 4;
}
 
UI_ThemeColor4(TH_TEXT);

Modified: trunk/blender/source/blender/editors/space_file/filesel.c
===
--- trunk/blender/source/blender/editors/space_file/filesel.c   2011-06-05 
13:59:04 UTC (rev 37209)
+++ trunk/blender/source/blender/editors/space_file/filesel.c   2011-06-05 
14:00:06 UTC (rev 37210)
@@ -403,10 +403,12 @@
uiStyleFontSet(style-widget);
s = BLF_height(style-widget.uifont_id, tmp);
return style-widget.points;
-#else
+#elif 0
uiStyle *style= U.uistyles.first;
uiStyleFontSet(style-widget);
return style-widget.points;
+#else
+   return UI_UNIT_Y * 0.f;
 #endif
 }
 
@@ -497,11 +499,11 @@
column_widths(sfile-files, layout);
 
if (params-display == FILE_SHORTDISPLAY) {
-   maxlen = ICON_DEFAULT_WIDTH + 4 +
+   maxlen = ICON_DEFAULT_WIDTH_SCALE + 4 +
 
(int)layout-column_widths[COLUMN_NAME] + 12 +
 
(int)layout-column_widths[COLUMN_SIZE] + 12;
} else {
-   maxlen = ICON_DEFAULT_WIDTH + 4 +
+   maxlen = ICON_DEFAULT_WIDTH_SCALE + 4 +
 
(int)layout-column_widths[COLUMN_NAME] + 12 +
 #ifndef WIN32
 
(int)layout-column_widths[COLUMN_MODE1] + 12 +

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37211] branches/soc-2011-onion/source/ blender/blenlib/intern/pbvh.c: unused variables in bli/pbvh.c

2011-06-05 Thread Jason Wilkins
Revision: 37211
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37211
Author:   jwilkins
Date: 2011-06-05 14:33:15 + (Sun, 05 Jun 2011)
Log Message:
---
unused variables in bli/pbvh.c

I'm confused why this conflict only appeared when merging onion into salad but 
not when merging trunk into onion.

Modified Paths:
--
branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c

Modified: branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
===
--- branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
2011-06-05 14:00:06 UTC (rev 37210)
+++ branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
2011-06-05 14:33:15 UTC (rev 37211)
@@ -179,17 +179,17 @@
 static int pbvh_planes_contain_AABB(float bb_min[3], float bb_max[3], float 
(*planes)[4])
 {
int i, axis;
-   float vmin[3], vmax[3];
+   float vmin[3]/*, vmax[3]*/;
 
for(i = 0; i  4; ++i) { 
for(axis = 0; axis  3; ++axis) {
if(planes[i][axis]  0) { 
vmin[axis] = bb_min[axis];
-   vmax[axis] = bb_max[axis];
+   /*vmax[axis] = bb_max[axis];*/ /*UNUSED*/
}
else {
vmin[axis] = bb_max[axis];
-   vmax[axis] = bb_min[axis];
+   /*vmax[axis] = bb_min[axis];*/ /*UNUSED*/
}
}

@@ -812,7 +812,7 @@
node= iter-stack[iter-stacksize].node;
 
/* on a mesh with no faces this can happen
-   * can remove this check if we know meshes have at least 1 face 
*/
+* can remove this check if we know meshes have at least 1 face 
*/
if(node==NULL) return NULL;
 
if(iter-scb  !iter-scb(node, iter-search_data)) continue; 
/* don't traverse, outside of search zone */
@@ -1128,19 +1128,19 @@
if(node-flag  PBVH_UpdateVertBuffers) {
if(bvh-grids) {
GPU_update_grid_vert_buffers(node-draw_buffers,
-bvh-grids,
-node-prim_indices,
-node-totprim,
-bvh-gridsize,
+  bvh-grids,
+  node-prim_indices,
+  node-totprim,
+  bvh-gridsize,
 bvh-gridkey,
-smooth);
+  smooth);
}
else {
GPU_update_mesh_vert_buffers(node-draw_buffers,
-bvh-verts,
-node-vert_indices,
-node-uniq_verts +
-node-face_verts);
+  bvh-verts,
+  node-vert_indices,
+  node-uniq_verts +
+  node-face_verts);
}
 
node-flag = ~PBVH_UpdateVertBuffers;
@@ -1155,14 +1155,14 @@
  bvh-gridsize,
  bvh-gridkey,
  bvh-vdata);
-   }
+   }
else {

GPU_update_mesh_color_buffers(node-draw_buffers,
  bvh-vdata,
  
node-vert_indices,
  node-uniq_verts +
  node-face_verts);
-   }
+}
 
node-flag = ~PBVH_UpdateColorBuffers;
}
@@ -1461,7 +1461,7 @@
float dist;
 
if ((isect_ray_tri_epsilon_v3(ray_start, ray_normal, t0, t1, t2, dist, 
NULL, 0.1f)  dist  *fdist) ||
-   (t3  isect_ray_tri_epsilon_v3(ray_start, ray_normal, t0, t2, 
t3, dist, NULL, 0.1f)  dist  *fdist))
+  

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37212] branches/soc-2011-salad: Merged onion branch

2011-06-05 Thread Jason Wilkins
Revision: 37212
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37212
Author:   jwilkins
Date: 2011-06-05 14:49:11 + (Sun, 05 Jun 2011)
Log Message:
---
Merged onion branch

Everything merged pretty cleanly.  There are problems with the blender manpage 
file, looks like the eol-style is wrong, but the property seems to be set right 
(every time I merge this file gets completely replaced)

Tried to test compile, but there are build errors from rna_fcurve.c that were 
introduced in 35172 I think (undefined identifiers min and max)

Modified Paths:
--
branches/soc-2011-salad/CMakeLists.txt
branches/soc-2011-salad/build_files/scons/config/aix4-config.py
branches/soc-2011-salad/build_files/scons/config/darwin-config.py
branches/soc-2011-salad/build_files/scons/config/freebsd7-config.py
branches/soc-2011-salad/build_files/scons/config/freebsd8-config.py
branches/soc-2011-salad/build_files/scons/config/freebsd9-config.py
branches/soc-2011-salad/build_files/scons/config/irix6-config.py
branches/soc-2011-salad/build_files/scons/config/linux2-config.py
branches/soc-2011-salad/build_files/scons/config/linuxcross-config.py
branches/soc-2011-salad/build_files/scons/config/openbsd3-config.py
branches/soc-2011-salad/build_files/scons/config/sunos5-config.py
branches/soc-2011-salad/build_files/scons/config/win32-mingw-config.py
branches/soc-2011-salad/build_files/scons/config/win32-vc-config.py
branches/soc-2011-salad/build_files/scons/config/win64-vc-config.py
branches/soc-2011-salad/build_files/scons/tools/btools.py
branches/soc-2011-salad/intern/ghost/SConscript
branches/soc-2011-salad/intern/ghost/intern/GHOST_WindowCarbon.cpp
branches/soc-2011-salad/intern/ghost/intern/GHOST_WindowCocoa.mm
branches/soc-2011-salad/intern/ghost/intern/GHOST_WindowWin32.cpp
branches/soc-2011-salad/intern/ghost/intern/GHOST_WindowX11.cpp
branches/soc-2011-salad/release/scripts/startup/bl_ui/properties_texture.py
branches/soc-2011-salad/release/scripts/startup/bl_ui/space_userpref.py
branches/soc-2011-salad/release/scripts/startup/bl_ui/space_view3d.py

branches/soc-2011-salad/release/scripts/startup/bl_ui/space_view3d_toolbar.py
branches/soc-2011-salad/source/blender/blenkernel/BKE_DerivedMesh.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_blender.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_brush.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_customdata.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_material.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_mesh.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_paint.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_subsurf.h
branches/soc-2011-salad/source/blender/blenkernel/BKE_texture.h
branches/soc-2011-salad/source/blender/blenkernel/intern/CCGSubSurf.c
branches/soc-2011-salad/source/blender/blenkernel/intern/CCGSubSurf.h
branches/soc-2011-salad/source/blender/blenkernel/intern/brush.c
branches/soc-2011-salad/source/blender/blenkernel/intern/cdderivedmesh.c
branches/soc-2011-salad/source/blender/blenkernel/intern/customdata.c
branches/soc-2011-salad/source/blender/blenkernel/intern/material.c
branches/soc-2011-salad/source/blender/blenkernel/intern/mesh.c
branches/soc-2011-salad/source/blender/blenkernel/intern/multires.c
branches/soc-2011-salad/source/blender/blenkernel/intern/object.c
branches/soc-2011-salad/source/blender/blenkernel/intern/paint.c
branches/soc-2011-salad/source/blender/blenkernel/intern/shrinkwrap.c
branches/soc-2011-salad/source/blender/blenkernel/intern/subsurf_ccg.c
branches/soc-2011-salad/source/blender/blenkernel/intern/texture.c
branches/soc-2011-salad/source/blender/blenlib/BLI_editVert.h
branches/soc-2011-salad/source/blender/blenlib/BLI_math_vector.h
branches/soc-2011-salad/source/blender/blenlib/BLI_pbvh.h
branches/soc-2011-salad/source/blender/blenlib/BLI_utildefines.h
branches/soc-2011-salad/source/blender/blenlib/intern/math_vector_inline.c
branches/soc-2011-salad/source/blender/blenlib/intern/pbvh.c
branches/soc-2011-salad/source/blender/blenloader/intern/readfile.c
branches/soc-2011-salad/source/blender/blenloader/intern/writefile.c
branches/soc-2011-salad/source/blender/editors/include/ED_mesh.h
branches/soc-2011-salad/source/blender/editors/include/ED_sculpt.h

branches/soc-2011-salad/source/blender/editors/interface/interface_templates.c
branches/soc-2011-salad/source/blender/editors/interface/resources.c
branches/soc-2011-salad/source/blender/editors/mesh/mesh_data.c
branches/soc-2011-salad/source/blender/editors/sculpt_paint/CMakeLists.txt
branches/soc-2011-salad/source/blender/editors/sculpt_paint/SConscript

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37213] branches/soc-2011-salad/source/ blender/makesrna/intern/rna_fcurve.c: Salad Branch: fix compile error, looks like mistake in merge confict res

2011-06-05 Thread Brecht Van Lommel
Revision: 37213
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37213
Author:   blendix
Date: 2011-06-05 15:25:43 + (Sun, 05 Jun 2011)
Log Message:
---
Salad Branch: fix compile error, looks like mistake in merge confict resolution.

Modified Paths:
--
branches/soc-2011-salad/source/blender/makesrna/intern/rna_fcurve.c

Modified: branches/soc-2011-salad/source/blender/makesrna/intern/rna_fcurve.c
===
--- branches/soc-2011-salad/source/blender/makesrna/intern/rna_fcurve.c 
2011-06-05 14:49:11 UTC (rev 37212)
+++ branches/soc-2011-salad/source/blender/makesrna/intern/rna_fcurve.c 
2011-06-05 15:25:43 UTC (rev 37213)
@@ -454,7 +454,7 @@
fm-flag |= FMODIFIER_FLAG_ACTIVE;
 }
 
-static void rna_FModifier_active_update(Main *UNUSED(bmain), Scene 
*UNUSED(scene), PointerRNA *ptr)
+static void rna_FModifier_start_frame_range(PointerRNA *ptr, float *min, float 
*max)
 {
FModifier *fcm= (FModifier*)ptr-data;


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37214] trunk/blender/source/blender/ blenlib/intern/path_util.c: own commit r37199 gave problems with duplicating objects, use different fix.

2011-06-05 Thread Campbell Barton
Revision: 37214
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37214
Author:   campbellbarton
Date: 2011-06-05 15:29:50 + (Sun, 05 Jun 2011)
Log Message:
---
own commit r37199 gave problems with duplicating objects, use different fix.

Revision Links:
--

http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37199

Modified Paths:
--
trunk/blender/source/blender/blenlib/intern/path_util.c

Modified: trunk/blender/source/blender/blenlib/intern/path_util.c
===
--- trunk/blender/source/blender/blenlib/intern/path_util.c 2011-06-05 
15:25:43 UTC (rev 37213)
+++ trunk/blender/source/blender/blenlib/intern/path_util.c 2011-06-05 
15:29:50 UTC (rev 37214)
@@ -156,7 +156,7 @@
 
/* could use '0', but this would mean the first
 * duplicate would become FooBar.000 */
-   *nr= 1;
+   *nr= 0;
a= strlen(name);
memcpy(left, name, (a + 1) * sizeof(char));
 
@@ -218,13 +218,13 @@
int number;
int len= BLI_split_name_num(left, number, name, 
delim);
do {
-   int newlen= BLI_snprintf(tempname, name_len, 
%s%c%03d, left, delim, number);
+   int newlen= BLI_snprintf(tempname, name_len, 
%s%c%03d, left, delim, ++number);
if(newlen = name_len) {
len -= ((newlen + 1) - name_len);
if(len  0) len= number= 0;
left[len]= '\0';
}
-   } while(number++, unique_check(arg, tempname));
+   } while(unique_check(arg, tempname));
 
BLI_strncpy(name, tempname, name_len);


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37215] trunk/blender/source/blender: operator buttons get a red highlight when alert is set for the layout

2011-06-05 Thread Campbell Barton
Revision: 37215
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37215
Author:   campbellbarton
Date: 2011-06-05 17:02:57 + (Sun, 05 Jun 2011)
Log Message:
---
operator buttons get a red highlight when alert is set for the layout

Modified Paths:
--
trunk/blender/source/blender/blenlib/intern/path_util.c
trunk/blender/source/blender/editors/interface/interface_layout.c

Modified: trunk/blender/source/blender/blenlib/intern/path_util.c
===
--- trunk/blender/source/blender/blenlib/intern/path_util.c 2011-06-05 
15:29:50 UTC (rev 37214)
+++ trunk/blender/source/blender/blenlib/intern/path_util.c 2011-06-05 
17:02:57 UTC (rev 37215)
@@ -154,8 +154,6 @@
 {
int a;
 
-   /* could use '0', but this would mean the first
-* duplicate would become FooBar.000 */
*nr= 0;
a= strlen(name);
memcpy(left, name, (a + 1) * sizeof(char));

Modified: trunk/blender/source/blender/editors/interface/interface_layout.c
===
--- trunk/blender/source/blender/editors/interface/interface_layout.c   
2011-06-05 15:29:50 UTC (rev 37214)
+++ trunk/blender/source/blender/editors/interface/interface_layout.c   
2011-06-05 17:02:57 UTC (rev 37215)
@@ -651,6 +651,9 @@
if (flag  UI_ITEM_R_NO_BG)
uiBlockSetEmboss(block, UI_EMBOSS);
 
+   if(layout-redalert)
+   uiButSetFlag(but, UI_BUT_REDALERT);
+
/* assign properties */
if(properties || (flag  UI_ITEM_O_RETURN_PROPS)) {
PointerRNA *opptr= uiButGetOperatorPtrRNA(but);

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37216] trunk/blender/source/blender/ blenloader/intern/readfile.c: fixed warning, signed/unsigned mismatch, blo/ readfile.c line 1742

2011-06-05 Thread Jason Wilkins
Revision: 37216
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37216
Author:   jwilkins
Date: 2011-06-05 18:00:24 + (Sun, 05 Jun 2011)
Log Message:
---
fixed warning, signed/unsigned mismatch, blo/readfile.c line 1742

Modified Paths:
--
trunk/blender/source/blender/blenloader/intern/readfile.c

Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===
--- trunk/blender/source/blender/blenloader/intern/readfile.c   2011-06-05 
17:02:57 UTC (rev 37215)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c   2011-06-05 
18:00:24 UTC (rev 37216)
@@ -1723,7 +1723,6 @@
 static void direct_link_fmodifiers(FileData *fd, ListBase *list)
 {
FModifier *fcm;
-   int a;

for (fcm= list-first; fcm; fcm= fcm-next) {
/* relink general data */
@@ -1739,6 +1738,7 @@
data-coefficients= newdataadr(fd, 
data-coefficients);
 
if(fd-flags  FD_FLAGS_SWITCH_ENDIAN) {
+   unsigned a;
for(a = 0; a  data-arraysize; a++)

SWITCH_INT(data-coefficients[a]);
}

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37217] branches/soc-2011-onion/source/ blender/makesrna/intern/rna_brush.c: rna_Brush_texture_angle_source_itemf in makesrna/rna_brush. c had the wro

2011-06-05 Thread Jason Wilkins
Revision: 37217
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37217
Author:   jwilkins
Date: 2011-06-05 18:35:18 + (Sun, 05 Jun 2011)
Log Message:
---
rna_Brush_texture_angle_source_itemf in makesrna/rna_brush.c had the wrong 
prototype

No consequence from this because the incorrect arguments are unused, but it 
does lead me to think that rna_*_gen.c files should be compiled with warnings 
as errors.

Modified Paths:
--
branches/soc-2011-onion/source/blender/makesrna/intern/rna_brush.c

Modified: branches/soc-2011-onion/source/blender/makesrna/intern/rna_brush.c
===
--- branches/soc-2011-onion/source/blender/makesrna/intern/rna_brush.c  
2011-06-05 18:00:24 UTC (rev 37216)
+++ branches/soc-2011-onion/source/blender/makesrna/intern/rna_brush.c  
2011-06-05 18:35:18 UTC (rev 37217)
@@ -334,7 +334,7 @@
}
 }
 
-static EnumPropertyItem *rna_Brush_texture_angle_source_itemf(bContext *C, 
PointerRNA *ptr, int *free)
+static EnumPropertyItem *rna_Brush_texture_angle_source_itemf(bContext 
*UNUSED(C), PointerRNA *ptr, PropertyRNA *UNUSED(prop), int *UNUSED(free))
 {
Brush *me= (Brush*)(ptr-data);
 

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37218] branches/soc-2010-nicks: synched with trunk at revision 37212

2011-06-05 Thread Nick Samarin
Revision: 37218
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37218
Author:   nicks
Date: 2011-06-05 18:51:00 + (Sun, 05 Jun 2011)
Log Message:
---
synched with trunk at revision 37212

Revision Links:
--

http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37212

Modified Paths:
--
branches/soc-2010-nicks/CMakeLists.txt
branches/soc-2010-nicks/build_files/buildbot/config/user-config-i686.py

branches/soc-2010-nicks/build_files/buildbot/config/user-config-player-i686.py

branches/soc-2010-nicks/build_files/buildbot/config/user-config-player-x86_64.py
branches/soc-2010-nicks/build_files/buildbot/config/user-config-x86_64.py
branches/soc-2010-nicks/build_files/buildbot/master.cfg
branches/soc-2010-nicks/build_files/buildbot/master_unpack.py
branches/soc-2010-nicks/build_files/buildbot/slave_compile.py
branches/soc-2010-nicks/build_files/buildbot/slave_pack.py
branches/soc-2010-nicks/build_files/cmake/cmake_qtcreator_project.py
branches/soc-2010-nicks/build_files/cmake/macros.cmake
branches/soc-2010-nicks/build_files/cmake/packaging.cmake
branches/soc-2010-nicks/build_files/package_spec/rpm/blender.spec.in
branches/soc-2010-nicks/build_files/scons/config/linux2-config.py
branches/soc-2010-nicks/build_files/scons/config/win32-vc-config.py
branches/soc-2010-nicks/build_files/scons/config/win64-vc-config.py
branches/soc-2010-nicks/build_files/scons/tools/Blender.py
branches/soc-2010-nicks/build_files/scons/tools/btools.py
branches/soc-2010-nicks/doc/doxygen/doxygen.source
branches/soc-2010-nicks/extern/binreloc/CMakeLists.txt
branches/soc-2010-nicks/extern/bullet2/CMakeLists.txt

branches/soc-2010-nicks/extern/bullet2/src/BulletCollision/BroadphaseCollision/btAxisSweep3.h

branches/soc-2010-nicks/extern/bullet2/src/BulletCollision/CollisionDispatch/btConvexConvexAlgorithm.cpp
branches/soc-2010-nicks/extern/eltopo/CMakeLists.txt
branches/soc-2010-nicks/extern/glew/CMakeLists.txt
branches/soc-2010-nicks/extern/glew/include/GL/glew.h
branches/soc-2010-nicks/extern/glew/include/GL/glxew.h
branches/soc-2010-nicks/extern/glew/include/GL/wglew.h
branches/soc-2010-nicks/extern/glew/src/glew.c
branches/soc-2010-nicks/extern/libopenjpeg/CMakeLists.txt
branches/soc-2010-nicks/extern/libredcode/CMakeLists.txt
branches/soc-2010-nicks/extern/lzma/CMakeLists.txt
branches/soc-2010-nicks/extern/lzo/CMakeLists.txt
branches/soc-2010-nicks/extern/recastnavigation/CMakeLists.txt
branches/soc-2010-nicks/intern/audaspace/CMakeLists.txt
branches/soc-2010-nicks/intern/audaspace/SConscript
branches/soc-2010-nicks/intern/audaspace/ffmpeg/AUD_FFMPEGReader.cpp
branches/soc-2010-nicks/intern/boolop/CMakeLists.txt
branches/soc-2010-nicks/intern/bsp/CMakeLists.txt
branches/soc-2010-nicks/intern/bsp/SConscript
branches/soc-2010-nicks/intern/bsp/test/BSP_GhostTest/BSP_GhostTest.dsp
branches/soc-2010-nicks/intern/bsp/test/BSP_GhostTest/BSP_GhostTest.dsw
branches/soc-2010-nicks/intern/container/CMakeLists.txt
branches/soc-2010-nicks/intern/container/CTR_TaggedIndex.h
branches/soc-2010-nicks/intern/decimation/CMakeLists.txt
branches/soc-2010-nicks/intern/decimation/SConscript
branches/soc-2010-nicks/intern/elbeem/CMakeLists.txt
branches/soc-2010-nicks/intern/ghost/CMakeLists.txt
branches/soc-2010-nicks/intern/ghost/intern/GHOST_ISystem.cpp
branches/soc-2010-nicks/intern/ghost/intern/GHOST_NDOFManager.cpp
branches/soc-2010-nicks/intern/ghost/intern/GHOST_SystemWin32.cpp
branches/soc-2010-nicks/intern/ghost/intern/GHOST_SystemWin32.h
branches/soc-2010-nicks/intern/ghost/intern/GHOST_SystemX11.cpp
branches/soc-2010-nicks/intern/ghost/intern/GHOST_WindowCocoa.mm
branches/soc-2010-nicks/intern/ghost/intern/GHOST_WindowX11.cpp
branches/soc-2010-nicks/intern/ghost/intern/GHOST_WindowX11.h
branches/soc-2010-nicks/intern/guardedalloc/CMakeLists.txt
branches/soc-2010-nicks/intern/iksolver/CMakeLists.txt
branches/soc-2010-nicks/intern/iksolver/intern/IK_QSegment.cpp
branches/soc-2010-nicks/intern/itasc/CMakeLists.txt
branches/soc-2010-nicks/intern/memutil/CMakeLists.txt
branches/soc-2010-nicks/intern/mikktspace/CMakeLists.txt
branches/soc-2010-nicks/intern/moto/CMakeLists.txt
branches/soc-2010-nicks/intern/opennl/CMakeLists.txt
branches/soc-2010-nicks/intern/smoke/CMakeLists.txt
branches/soc-2010-nicks/intern/string/CMakeLists.txt
branches/soc-2010-nicks/release/scripts/modules/bpy/path.py
branches/soc-2010-nicks/release/scripts/modules/bpy/utils.py
branches/soc-2010-nicks/release/scripts/modules/bpy_types.py

branches/soc-2010-nicks/release/scripts/startup/bl_operators/add_mesh_torus.py
branches/soc-2010-nicks/release/scripts/startup/bl_operators/mesh.py


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37219] branches/soc-2011-pepper/source/ blender/collada: Add new animation export features.

2011-06-05 Thread Sukhitha Jayathilake
Revision: 37219
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37219
Author:   phabtar
Date: 2011-06-05 18:58:22 + (Sun, 05 Jun 2011)
Log Message:
---
Add new animation export features.

- Bone animations are also exported as f-curve animations now. As a result 
euler rotaions of bones are also exported. All animations with BEZIER, LINEAR 
or STEP ipo are exported. 
- Quaternion rotations export.
- Object parented with armatures, animations to Armature Objects as a whole are 
also exported. 

Modified Paths:
--
branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp
branches/soc-2011-pepper/source/blender/collada/AnimationExporter.h

Modified: branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp
===
--- branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp   
2011-06-05 18:51:00 UTC (rev 37218)
+++ branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp   
2011-06-05 18:58:22 UTC (rev 37219)
@@ -55,41 +55,86 @@
void AnimationExporter::operator() (Object *ob) 
{
if (!ob-adt || !ob-adt-action) return;  //this is already 
checked in hasAnimations()
-   
FCurve *fcu = (FCurve*)ob-adt-action-curves.first;
-   
-   if (ob-type == OB_ARMATURE) {
-   if (!ob-data) return;
-
-   bArmature *arm = (bArmature*)ob-data;
-   for (Bone *bone = (Bone*)arm-bonebase.first; bone; 
bone = bone-next)
-   write_bone_animation(ob, bone);
-   }
-   else {
+   char * transformName = extract_transform_name( fcu-rna_path );
+
+   //if (ob-type == OB_ARMATURE) {
+   //  if (!ob-data) return;
+   //  bArmature *arm = (bArmature*)ob-data;
+   //  while(fcu)
+   //  {   
+   //  transformName = extract_transform_name( 
fcu-rna_path );
+   //  //  std::string ob_name =  getObjectBoneName( ob , 
fcu);
+   //  //  for (Bone *bone = (Bone*)arm-bonebase.first; 
bone; bone = bone-next)
+   //  //  write_bone_animation(ob, bone);
+   //  dae_animation(ob, fcu, ob_name, transformName);
+   //  fcu = fcu-next;
+   //  }
+   //}
+   //else {
while (fcu) {
-   // TODO rotation_quaternion is also possible 
for objects (although euler is default)
-   if ((!strcmp(fcu-rna_path, location) || 
!strcmp(fcu-rna_path, scale)) ||
-   (!strcmp(fcu-rna_path, 
rotation_euler)  ob-rotmode == ROT_MODE_EUL))
-   dae_animation(fcu, id_name(ob));
+   transformName = extract_transform_name( fcu-rna_path );
+   printf(fcu - rna _path : %s \n transformName 
: %s\n, fcu-rna_path, transformName);
+   if ((!strcmp(transformName, location) || 
!strcmp(transformName, scale)) ||
+   (!strcmp(transformName, 
rotation_euler)  ob-rotmode == ROT_MODE_EUL)||
+   (!strcmp(transformName, 
rotation_quaternion))) 
+   dae_animation(ob ,fcu,/* id_name(ob),*/ 
transformName);
 
fcu = fcu-next;
}
-   }
+   //}
}
 
-   void AnimationExporter::dae_animation(FCurve *fcu, std::string ob_name)
+   std::string AnimationExporter::getObjectBoneName( Object* ob,const 
FCurve* fcu ) 
{
-   const char *axis_names[] = {X, Y, Z};
+   //hard-way to derive the bone name from rna_path. Must find 
more compact method
+   std::string rna_path = std::string(fcu-rna_path);
+
+   char* boneName = strtok((char *)rna_path.c_str(), \);
+   boneName = strtok(NULL,\);
+   
+   if( boneName != NULL )
+   return id_name(ob) + _ + std::string(boneName);
+   else
+   return id_name(ob);
+   }
+
+   void AnimationExporter::dae_animation(Object* ob, FCurve *fcu/*, 
std::string ob_name*/ , char* transformName)
+   {
+   printf(in dae animation\n);
const char *axis_name = NULL;
char anim_id[200];
bool has_tangents = false;

-   if (fcu-array_index  3)
+   if ( !strcmp(transformName, rotation_quaternion) )
+   {
+   const 

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37220] branches/soc-2011-onion/source/ blender/blenlib/intern/pbvh.c: Warning fix and some paranoia

2011-06-05 Thread Jason Wilkins
Revision: 37220
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37220
Author:   jwilkins
Date: 2011-06-05 19:57:11 + (Sun, 05 Jun 2011)
Log Message:
---
Warning fix and some paranoia

map_insert_vert stores vertex indexes in a hash table, it uses the sign to 
indicate the type of vertex, the original index as unsigned, the conversion to 
a negative number caused a warning, this fixes it by explicitly casting to int, 
added an assertion that the index can't be greater than INT_MAX because that 
would be too big to distinguish it uses sign and it is undefined to cast 
unsigned to sign if the unsigned number is too big.

TODO: assert technically isn't enough because this check needs to be done in 
release code, although practically it is actually too much since it is unlikely 
we will be dealing with 2 billion vertexes any time soon, hence, paranoia

Modified Paths:
--
branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c

Modified: branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
===
--- branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
2011-06-05 18:58:22 UTC (rev 37219)
+++ branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
2011-06-05 19:57:11 UTC (rev 37220)
@@ -350,15 +350,17 @@
 
if(!BLI_ghash_haskey(map, key)) {
if(BLI_bitmap_get(bvh-vert_bitmap, vertex)) {
-   value = SET_INT_IN_POINTER(-(*face_verts) - 1); // XXX: 
MSVC says, warning C4146: unary minus operator applied to unsigned type, result 
still unsigned
+   assert(*face_verts  (unsigned)INT_MAX); // results of 
casting unsigned to signed is undefined
+   value = SET_INT_IN_POINTER(-(int)(*face_verts) - 1);
++(*face_verts);
}
else {
+   assert(*uniq_verts  (unsigned)INT_MAX); // results of 
casting unsigned to signed is undefined
BLI_bitmap_set(bvh-vert_bitmap, vertex);
-   value = SET_INT_IN_POINTER(*uniq_verts);
+   value = SET_INT_IN_POINTER((int)*uniq_verts);
++(*uniq_verts);
}
-   
+
BLI_ghash_insert(map, key, value);
return GET_INT_FROM_POINTER(value);
}

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37221] branches/soc-2011-onion/intern/ smoke/intern/MERSENNETWISTER.h: fixed signed/ unsigned warning in MERSENNETWISTER.h

2011-06-05 Thread Jason Wilkins
Revision: 37221
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37221
Author:   jwilkins
Date: 2011-06-05 20:22:24 + (Sun, 05 Jun 2011)
Log Message:
---
fixed signed/unsigned warning in MERSENNETWISTER.h

casting uint32 to int32 is safe for loBits because the value is 0 or 1, which 
is less than LONG_MAX
casting 0 or 1 back to uint32 is guaranteed by the standard to result in 0 or 
0x (respectively)
so, same results, but no warning
extra parens for readability

had to add int32 type to be used in this one place

Modified Paths:
--
branches/soc-2011-onion/intern/smoke/intern/MERSENNETWISTER.h

Modified: branches/soc-2011-onion/intern/smoke/intern/MERSENNETWISTER.h
===
--- branches/soc-2011-onion/intern/smoke/intern/MERSENNETWISTER.h   
2011-06-05 19:57:11 UTC (rev 37220)
+++ branches/soc-2011-onion/intern/smoke/intern/MERSENNETWISTER.h   
2011-06-05 20:22:24 UTC (rev 37221)
@@ -73,6 +73,7 @@
 // Data
 public:
typedef unsigned long uint32;  // unsigned integer type, at least 32 
bits
+   typedef signed long int32; // signed integer type, at least 32 bits

enum { N = 624 };   // length of state vector
enum { SAVE = N + 1 };  // length of array for save()
@@ -132,7 +133,7 @@
uint32 mixBits( const uint32 u, const uint32 v ) const
{ return hiBit(u) | loBits(v); }
uint32 twist( const uint32 m, const uint32 s0, const uint32 s1 ) 
const
-   { return m ^ (mixBits(s0,s1)1) ^ (-loBit(s1)  0x9908b0dfUL); 
}
+   { return m ^ (mixBits(s0,s1)1) ^ ((uint32)(-(int32)loBit(s1)) 
 0x9908b0dfUL); }
static uint32 hash( time_t t, clock_t c );
 };
 

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37222] branches/soc-2011-onion/intern/ audaspace/intern/AUD_ConverterFunctions.cpp: Fixed constant truncated warning in AUD_ConverterFunctions.cpp

2011-06-05 Thread Jason Wilkins
Revision: 37222
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37222
Author:   jwilkins
Date: 2011-06-05 20:34:13 + (Sun, 05 Jun 2011)
Log Message:
---
Fixed constant truncated warning in AUD_ConverterFunctions.cpp

Integer constants are sizeof(int) or greater depending on their values.  MSVC 
apparently is not clever enough to check if the value inside an int is actually 
truncated even though that could be used to prevent false alarms.  To silence 
the warning I just cast the constant to an int16_t.

Modified Paths:
--
branches/soc-2011-onion/intern/audaspace/intern/AUD_ConverterFunctions.cpp

Modified: 
branches/soc-2011-onion/intern/audaspace/intern/AUD_ConverterFunctions.cpp
===
--- branches/soc-2011-onion/intern/audaspace/intern/AUD_ConverterFunctions.cpp  
2011-06-05 20:22:24 UTC (rev 37221)
+++ branches/soc-2011-onion/intern/audaspace/intern/AUD_ConverterFunctions.cpp  
2011-06-05 20:34:13 UTC (rev 37222)
@@ -33,8 +33,8 @@
 #include AUD_Buffer.h
 
 #define AUD_U8_0   0x80
-#define AUD_S16_MAX0x7FFF
-#define AUD_S16_MIN0x8000
+#define AUD_S16_MAX((int16_t)0x7FFF)
+#define AUD_S16_MIN((int16_t)0x8000)
 #define AUD_S16_FLT32768.0f
 #define AUD_S32_MAX0x7FFF
 #define AUD_S32_MIN0x8000

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37223] branches/soc-2011-onion/source/ blender/editors/sculpt_paint/paint_mask.c: Copyright and file header

2011-06-05 Thread Jason Wilkins
Revision: 37223
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37223
Author:   jwilkins
Date: 2011-06-05 20:40:10 + (Sun, 05 Jun 2011)
Log Message:
---
Copyright and file header

Modified Paths:
--
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_mask.c

Modified: 
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_mask.c
===
--- branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_mask.c
2011-06-05 20:34:13 UTC (rev 37222)
+++ branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_mask.c
2011-06-05 20:40:10 UTC (rev 37223)
@@ -1,3 +1,37 @@
+/*
+ * $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) 2010 by Nicholas Bishop
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s):
+ *
+ * * END GPL LICENSE BLOCK *
+ *
+ */
+
+/** \file blender/editors/sculpt_paint/paint_mask.c
+ *  \ingroup edsculpt
+ */
+
 #include stdio.h
 #include stdlib.h
 #include string.h

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37224] branches/soc-2011-onion/source/ blender/blenloader/intern/readfile.c: fixed signed/ unsigned mismatch warning

2011-06-05 Thread Jason Wilkins
Revision: 37224
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37224
Author:   jwilkins
Date: 2011-06-05 20:44:50 + (Sun, 05 Jun 2011)
Log Message:
---
fixed signed/unsigned mismatch warning

Modified Paths:
--
branches/soc-2011-onion/source/blender/blenloader/intern/readfile.c

Modified: branches/soc-2011-onion/source/blender/blenloader/intern/readfile.c
===
--- branches/soc-2011-onion/source/blender/blenloader/intern/readfile.c 
2011-06-05 20:40:10 UTC (rev 37223)
+++ branches/soc-2011-onion/source/blender/blenloader/intern/readfile.c 
2011-06-05 20:44:50 UTC (rev 37224)
@@ -1723,7 +1723,6 @@
 static void direct_link_fmodifiers(FileData *fd, ListBase *list)
 {
FModifier *fcm;
-   int a;

for (fcm= list-first; fcm; fcm= fcm-next) {
/* relink general data */
@@ -1739,6 +1738,7 @@
data-coefficients= newdataadr(fd, 
data-coefficients);
 
if(fd-flags  FD_FLAGS_SWITCH_ENDIAN) {
+   unsigned a;
for(a = 0; a  data-arraysize; a++)

SWITCH_INT(data-coefficients[a]);
}

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37225] trunk/blender: Bake from multires mesh

2011-06-05 Thread Sergey Sharybin
Revision: 37225
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37225
Author:   nazgul
Date: 2011-06-05 20:54:04 + (Sun, 05 Jun 2011)
Log Message:
---
Bake from multires mesh
===

Added option to baked named Bake From Multires which is avaliable for
normals baking and displacement baking.

If this option is enabled, then no additional hi-res meshes and render
structures would be created . This saves plenty of memory and meshes
with millions of faces could be successfully baked in few minutes.

Baking happens from highest level against viewport subdivision level,
so workflow is following:
  - Set viewport level to level at which texture would be applied
during final rendering.
  - Choose Displacement/Normals baking.
  - Enable Bake From Multires option.
  - You're ready to bake.

Displacement baker had aditional option named Low Resolution Mesh.
This option is used to set if you want texture for realtime (games)
usage.

Internally it does the following:
  - If it's disabled, displacement is calculated from subdivided
viewport level, so texture looks smooth (it's how default
baked works).
  - If it's enabled, dispalcement is calculated against unsubdivided
viewport levels. This leads to scales. This isn;t useful for
offline renders much, but very useful for creating game textures.

Special thanks to Morten Mikkelsen (aka sparky) for all mathematics
and other work he've done fr this patch!

Modified Paths:
--
trunk/blender/release/scripts/startup/bl_ui/properties_render.py
trunk/blender/source/blender/blenkernel/BKE_multires.h
trunk/blender/source/blender/blenkernel/intern/customdata.c
trunk/blender/source/blender/blenkernel/intern/multires.c
trunk/blender/source/blender/blenlib/BLI_math_geom.h
trunk/blender/source/blender/blenlib/intern/math_geom.c
trunk/blender/source/blender/editors/object/object_bake.c
trunk/blender/source/blender/imbuf/IMB_imbuf.h
trunk/blender/source/blender/imbuf/intern/filter.c
trunk/blender/source/blender/makesdna/DNA_scene_types.h
trunk/blender/source/blender/makesrna/intern/rna_scene.c
trunk/blender/source/blender/render/intern/source/rendercore.c

Modified: trunk/blender/release/scripts/startup/bl_ui/properties_render.py
===
--- trunk/blender/release/scripts/startup/bl_ui/properties_render.py
2011-06-05 20:44:50 UTC (rev 37224)
+++ trunk/blender/release/scripts/startup/bl_ui/properties_render.py
2011-06-05 20:54:04 UTC (rev 37225)
@@ -613,29 +613,41 @@
 
 layout.prop(rd, bake_type)
 
-if rd.bake_type == 'NORMALS':
-layout.prop(rd, bake_normal_space)
-elif rd.bake_type in {'DISPLACEMENT', 'AO'}:
-layout.prop(rd, use_bake_normalize)
+multires_bake = False
+if rd.bake_type in ['NORMALS', 'DISPLACEMENT']:
+layout.prop(rd, 'use_bake_multires')
+multires_bake = rd.use_bake_multires
 
-# col.prop(rd, bake_aa_mode)
-# col.prop(rd, use_bake_antialiasing)
+if not multires_bake:
+if rd.bake_type == 'NORMALS':
+layout.prop(rd, bake_normal_space)
+elif rd.bake_type in {'DISPLACEMENT', 'AO'}:
+layout.prop(rd, use_bake_normalize)
 
-layout.separator()
+# col.prop(rd, bake_aa_mode)
+# col.prop(rd, use_bake_antialiasing)
 
-split = layout.split()
+layout.separator()
 
-col = split.column()
-col.prop(rd, use_bake_clear)
-col.prop(rd, bake_margin)
-col.prop(rd, bake_quad_split, text=Split)
+split = layout.split()
 
-col = split.column()
-col.prop(rd, use_bake_selected_to_active)
-sub = col.column()
-sub.active = rd.use_bake_selected_to_active
-sub.prop(rd, bake_distance)
-sub.prop(rd, bake_bias)
+col = split.column()
+col.prop(rd, use_bake_clear)
+col.prop(rd, bake_margin)
+col.prop(rd, bake_quad_split, text=Split)
 
+col = split.column()
+col.prop(rd, use_bake_selected_to_active)
+sub = col.column()
+sub.active = rd.use_bake_selected_to_active
+sub.prop(rd, bake_distance)
+sub.prop(rd, bake_bias)
+else:
+if rd.bake_type == 'DISPLACEMENT':
+layout.prop(rd, use_bake_lores_mesh)
+
+layout.prop(rd, use_bake_clear)
+layout.prop(rd, bake_margin)
+
 if __name__ == __main__:  # only for live edit.
 bpy.utils.register_module(__name__)

Modified: trunk/blender/source/blender/blenkernel/BKE_multires.h
===
--- trunk/blender/source/blender/blenkernel/BKE_multires.h  2011-06-05 
20:44:50 UTC (rev 37224)
+++ 

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37226] branches/soc-2011-pepper: 3D Audio GSoC:

2011-06-05 Thread Joerg Mueller
Revision: 37226
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37226
Author:   nexyon
Date: 2011-06-05 22:06:29 + (Sun, 05 Jun 2011)
Log Message:
---
3D Audio GSoC:
Making it possible to access blenders internal sounds via Python.

Modified Paths:
--
branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.cpp
branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.h
branches/soc-2011-pepper/intern/audaspace/intern/AUD_C-API.cpp
branches/soc-2011-pepper/release/scripts/modules/bpy_types.py
branches/soc-2011-pepper/source/blender/blenkernel/BKE_sound.h
branches/soc-2011-pepper/source/blender/blenkernel/intern/sound.c

Modified: branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.cpp
===
--- branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.cpp  
2011-06-05 20:54:04 UTC (rev 37225)
+++ branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.cpp  
2011-06-05 22:06:29 UTC (rev 37226)
@@ -2875,6 +2875,12 @@
return DeviceType.tp_alloc(DeviceType, 0);
 }
 
+PyObject *
+Factory_empty()
+{
+   return FactoryType.tp_alloc(FactoryType, 0);
+}
+
 // 
 
 PyDoc_STRVAR(M_aud_doc,

Modified: branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.h
===
--- branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.h
2011-06-05 20:54:04 UTC (rev 37225)
+++ branches/soc-2011-pepper/intern/audaspace/Python/AUD_PyAPI.h
2011-06-05 22:06:29 UTC (rev 37226)
@@ -66,8 +66,8 @@
 PyMODINIT_FUNC
 PyInit_aud(void);
 
-extern PyObject *
-Device_empty();
+extern PyObject* Device_empty();
+extern PyObject* Factory_empty();
 
 #ifdef __cplusplus
 }

Modified: branches/soc-2011-pepper/intern/audaspace/intern/AUD_C-API.cpp
===
--- branches/soc-2011-pepper/intern/audaspace/intern/AUD_C-API.cpp  
2011-06-05 20:54:04 UTC (rev 37225)
+++ branches/soc-2011-pepper/intern/audaspace/intern/AUD_C-API.cpp  
2011-06-05 22:06:29 UTC (rev 37226)
@@ -181,10 +181,48 @@

  :return: The application's :class:`Device`.\n

  :rtype: :class:`Device`}};
 
+extern C {
+extern void* sound_get_factory(void* sound);
+}
+
+static PyObject* AUD_getSoundFromPointer(PyObject* self, PyObject* args)
+{
+   long int lptr;
+
+   if(PyArg_Parse(args, l:_sound_from_pointer, lptr))
+   {
+   if(lptr)
+   {
+   AUD_ReferenceAUD_IFactory* factory = 
(AUD_ReferenceAUD_IFactory*) sound_get_factory((void*) lptr);
+
+   if(factory)
+   {
+   Factory* obj = (Factory*) Factory_empty();
+   if(obj)
+   {
+   obj-factory = new 
AUD_ReferenceAUD_IFactory(*factory);
+   return (PyObject*) obj;
+   }
+   }
+   }
+   }
+
+   Py_RETURN_NONE;
+}
+
+static PyMethodDef meth_sound_from_pointer[] = {{ _sound_from_pointer, 
(PyCFunction)AUD_getSoundFromPointer, METH_O,
+   
  _sound_from_pointer(pointer)\n\n
+   
  Returns the corresponding :class:`Factory` object.\n\n
+   
  :arg pointer: The pointer to the bSound object as long.\n
+   
  :type pointer: long\n
+   
  :return: The corresponding :class:`Factory` object.\n
+   
  :rtype: :class:`Factory`}};
+
 PyObject* AUD_initPython()
 {
PyObject* module = PyInit_aud();
-   PyModule_AddObject(module, device, (PyObject 
*)PyCFunction_New(meth_getcdevice, NULL));
+   PyModule_AddObject(module, device, 
(PyObject*)PyCFunction_New(meth_getcdevice, NULL));
+   PyModule_AddObject(module, _sound_from_pointer, 
(PyObject*)PyCFunction_New(meth_sound_from_pointer, NULL));
PyDict_SetItemString(PyImport_GetModuleDict(), aud, module);
 
return module;

Modified: branches/soc-2011-pepper/release/scripts/modules/bpy_types.py
===
--- branches/soc-2011-pepper/release/scripts/modules/bpy_types.py   
2011-06-05 20:54:04 UTC (rev 

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37227] trunk/blender/source/blender/ render/intern/source/volumetric.c: Fix [#27438] Volume Material Density Inaccuracy

2011-06-05 Thread Matt Ebb
Revision: 37227
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37227
Author:   broken
Date: 2011-06-05 22:35:37 + (Sun, 05 Jun 2011)
Log Message:
---
Fix [#27438] Volume Material Density Inaccuracy

Lower density limit for shading optimisation was set too high

Modified Paths:
--
trunk/blender/source/blender/render/intern/source/volumetric.c

Modified: trunk/blender/source/blender/render/intern/source/volumetric.c
===
--- trunk/blender/source/blender/render/intern/source/volumetric.c  
2011-06-05 22:06:29 UTC (rev 37226)
+++ trunk/blender/source/blender/render/intern/source/volumetric.c  
2011-06-05 22:35:37 UTC (rev 37227)
@@ -605,7 +605,7 @@
for (; t0  t1; pt0 = t0, t0 += stepsize) {
const float density = vol_get_density(shi, p);

-   if (density  0.01f) {
+   if (density  0.1f) {
float scatter_col[3] = {0.f, 0.f, 0.f}, emit_col[3];
const float stepd = (t0 - pt0) * density;


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37228] branches/soc-2011-onion/source/ blender/blenlib/intern/pbvh.c: added limits.h to bli/pbvh.c

2011-06-05 Thread Jason Wilkins
Revision: 37228
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37228
Author:   jwilkins
Date: 2011-06-05 23:09:03 + (Sun, 05 Jun 2011)
Log Message:
---
added limits.h to bli/pbvh.c

Modified Paths:
--
branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c

Modified: branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
===
--- branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
2011-06-05 22:35:37 UTC (rev 37227)
+++ branches/soc-2011-onion/source/blender/blenlib/intern/pbvh.c
2011-06-05 23:09:03 UTC (rev 37228)
@@ -44,6 +44,8 @@
 
 #include GPU_buffers.h
 
+#include limits.h
+
 static void pbvh_free_nodes(PBVH *bvh);
 
 #define LEAF_LIMIT 1

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37231] trunk/blender/release/scripts/ startup/bl_ui/properties_object_constraint.py: replacing - arrows by proper ASCII arrows on Transformation Con

2011-06-05 Thread Dalai Felinto
Revision: 37231
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37231
Author:   dfelinto
Date: 2011-06-05 23:38:11 + (Sun, 05 Jun 2011)
Log Message:
---
replacing - arrows by proper ASCII arrows on Transformation Constraint

Note: Text Editor doesn't support this chr(187) properly. I hardcoded and 
commented the ui file. I hope it's fine.

Modified Paths:
--
trunk/blender/release/scripts/startup/bl_ui/properties_object_constraint.py

Modified: 
trunk/blender/release/scripts/startup/bl_ui/properties_object_constraint.py
===
--- trunk/blender/release/scripts/startup/bl_ui/properties_object_constraint.py 
2011-06-05 23:14:59 UTC (rev 37230)
+++ trunk/blender/release/scripts/startup/bl_ui/properties_object_constraint.py 
2011-06-05 23:38:11 UTC (rev 37231)
@@ -655,17 +655,19 @@
 row = col.row()
 row.label(text=Source to Destination Mapping:)
 
+   # note: chr(187) is the ASCII arrow (  ). Blender Text Editor 
can't
+   # open it. Thus we are using the hardcoded value instead.
 row = col.row()
 row.prop(con, map_to_x_from, expand=False, text=)
-row.label(text= - X)
+row.label(text= %sX % chr(187))
 
 row = col.row()
 row.prop(con, map_to_y_from, expand=False, text=)
-row.label(text= - Y)
+row.label(text= %sY % chr(187))
 
 row = col.row()
 row.prop(con, map_to_z_from, expand=False, text=)
-row.label(text= - Z)
+row.label(text= %sZ % chr(187))
 
 split = layout.split()
 

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37232] trunk/blender/source/blender: fix for crash opening the file selector twice with multiple windows open ( when the mouse was over the inactive

2011-06-05 Thread Campbell Barton
Revision: 37232
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37232
Author:   campbellbarton
Date: 2011-06-06 00:42:36 + (Mon, 06 Jun 2011)
Log Message:
---
fix for crash opening the file selector twice with multiple windows open (when 
the mouse was over the inactive window).

Modified Paths:
--
trunk/blender/source/blender/blenloader/intern/readfile.c
trunk/blender/source/blender/editors/include/ED_screen.h
trunk/blender/source/blender/editors/render/render_view.c
trunk/blender/source/blender/editors/screen/screen_edit.c
trunk/blender/source/blender/windowmanager/intern/wm_event_system.c

Modified: trunk/blender/source/blender/blenloader/intern/readfile.c
===
--- trunk/blender/source/blender/blenloader/intern/readfile.c   2011-06-05 
23:38:11 UTC (rev 37231)
+++ trunk/blender/source/blender/blenloader/intern/readfile.c   2011-06-06 
00:42:36 UTC (rev 37232)
@@ -1738,7 +1738,7 @@
data-coefficients= newdataadr(fd, 
data-coefficients);
 
if(fd-flags  FD_FLAGS_SWITCH_ENDIAN) {
-   unsigned a;
+   unsigned int a;
for(a = 0; a  data-arraysize; a++)

SWITCH_INT(data-coefficients[a]);
}

Modified: trunk/blender/source/blender/editors/include/ED_screen.h
===
--- trunk/blender/source/blender/editors/include/ED_screen.h2011-06-05 
23:38:11 UTC (rev 37231)
+++ trunk/blender/source/blender/editors/include/ED_screen.h2011-06-06 
00:42:36 UTC (rev 37232)
@@ -107,7 +107,7 @@
 void   ED_screen_exit(struct bContext *C, struct wmWindow *window, struct 
bScreen *screen);
 void   ED_screen_animation_timer(struct bContext *C, int redraws, int refresh, 
int sync, int enable);
 void   ED_screen_animation_timer_update(struct bScreen *screen, int redraws, 
int refresh);
-intED_screen_full_newspace(struct bContext *C, ScrArea *sa, int 
type);
+ScrArea *ED_screen_full_newspace(struct bContext *C, ScrArea *sa, int type);
 void   ED_screen_full_prevspace(struct bContext *C, ScrArea *sa);
 void   ED_screen_full_restore(struct bContext *C, ScrArea *sa);
 struct ScrArea *ED_screen_full_toggle(struct bContext *C, struct wmWindow 
*win, struct ScrArea *sa);

Modified: trunk/blender/source/blender/editors/render/render_view.c
===
--- trunk/blender/source/blender/editors/render/render_view.c   2011-06-05 
23:38:11 UTC (rev 37231)
+++ trunk/blender/source/blender/editors/render/render_view.c   2011-06-06 
00:42:36 UTC (rev 37232)
@@ -184,8 +184,7 @@
area_was_image = 1;
 
/* this function returns with changed context */
-   ED_screen_full_newspace(C, CTX_wm_area(C), SPACE_IMAGE);
-   sa= CTX_wm_area(C);
+   sa= ED_screen_full_newspace(C, CTX_wm_area(C), SPACE_IMAGE);
}
 
if(!sa) {

Modified: trunk/blender/source/blender/editors/screen/screen_edit.c
===
--- trunk/blender/source/blender/editors/screen/screen_edit.c   2011-06-05 
23:38:11 UTC (rev 37231)
+++ trunk/blender/source/blender/editors/screen/screen_edit.c   2011-06-06 
00:42:36 UTC (rev 37232)
@@ -1513,7 +1513,7 @@
unlink_scene(bmain, scene, newscene);
 }
 
-int ED_screen_full_newspace(bContext *C, ScrArea *sa, int type)
+ScrArea *ED_screen_full_newspace(bContext *C, ScrArea *sa, int type)
 {
wmWindow *win= CTX_wm_window(C);
bScreen *screen= CTX_wm_screen(C);
@@ -1538,7 +1538,7 @@

ED_area_newspace(C, newsa, type);

-   return 1;
+   return newsa;
 }
 
 void ED_screen_full_prevspace(bContext *C, ScrArea *sa)

Modified: trunk/blender/source/blender/windowmanager/intern/wm_event_system.c
===
--- trunk/blender/source/blender/windowmanager/intern/wm_event_system.c 
2011-06-05 23:38:11 UTC (rev 37231)
+++ trunk/blender/source/blender/windowmanager/intern/wm_event_system.c 
2011-06-06 00:42:36 UTC (rev 37232)
@@ -1289,16 +1289,23 @@
if (handler-op_area == NULL) {
bScreen *screen = CTX_wm_screen(C);
sa = (ScrArea *)screen-areabase.first;
-   } else
+   }
+   else {
sa = handler-op_area;
+   }

-   if(event-val==EVT_FILESELECT_OPEN)
-  

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37233] trunk/blender/source/blender: spelling corrections

2011-06-05 Thread Campbell Barton
Revision: 37233
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37233
Author:   campbellbarton
Date: 2011-06-06 00:48:10 + (Mon, 06 Jun 2011)
Log Message:
---
spelling corrections

Modified Paths:
--
trunk/blender/source/blender/editors/screen/area.c
trunk/blender/source/blender/windowmanager/intern/wm_event_system.c

Modified: trunk/blender/source/blender/editors/screen/area.c
===
--- trunk/blender/source/blender/editors/screen/area.c  2011-06-06 00:42:36 UTC 
(rev 37232)
+++ trunk/blender/source/blender/editors/screen/area.c  2011-06-06 00:48:10 UTC 
(rev 37233)
@@ -1138,7 +1138,7 @@
/* tell WM to refresh, cursor types etc */
WM_event_add_mousemove(C);

-   /*send space change notifyer*/
+   /*send space change notifier*/
WM_event_add_notifier(C, NC_SPACE|ND_SPACE_CHANGED, sa);

ED_area_tag_refresh(sa);
@@ -1165,7 +1165,7 @@
}
ED_area_tag_redraw(sa);
 
-   /*send space change notifyer*/
+   /*send space change notifier*/
WM_event_add_notifier(C, NC_SPACE|ND_SPACE_CHANGED, sa);
 }
 
@@ -1213,7 +1213,7 @@
ED_area_newspace(C, CTX_wm_area(C), CTX_wm_area(C)-butspacetype);
ED_area_tag_redraw(CTX_wm_area(C));
 
-   /*send space change notifyer*/
+   /*send space change notifier*/
WM_event_add_notifier(C, NC_SPACE|ND_SPACE_CHANGED, CTX_wm_area(C));
 }
 

Modified: trunk/blender/source/blender/windowmanager/intern/wm_event_system.c
===
--- trunk/blender/source/blender/windowmanager/intern/wm_event_system.c 
2011-06-06 00:42:36 UTC (rev 37232)
+++ trunk/blender/source/blender/windowmanager/intern/wm_event_system.c 
2011-06-06 00:48:10 UTC (rev 37233)
@@ -340,7 +340,7 @@
int is_wheel= ELEM(event-type, WHEELUPMOUSE, WHEELDOWNMOUSE);
int retval;

-   /* UI is quite agressive with swallowing events, like scrollwheel */
+   /* UI is quite aggressive with swallowing events, like scrollwheel */
/* I realize this is not extremely nice code... when UI gets keymaps it 
can be maybe smarter */
if(do_wheel_ui==0) {
if(is_wheel)
@@ -1577,7 +1577,7 @@
 *   so check for mouse moves too.
 * note2: the first click event will be handled but 
still used to create a
 *   double click event if clicking again quickly.
-*   If no double click events are found itwill 
fallback to a single click.
+*   If no double click events are found it will 
fallback to a single click.
 *   So a double click event can result in 2 successive 
single click calls
 *   if its not handled by the keymap - campbell */
if ((ABS(event-x - win-eventstate-prevclickx)) 
= 2 

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37234] branches/soc-2011-onion: Revision: 30093

2011-06-05 Thread Jason Wilkins
Revision: 37234
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37234
Author:   jwilkins
Date: 2011-06-06 03:20:27 + (Mon, 06 Jun 2011)
Log Message:
---
Revision: 30093
Author: nicholasbishop
Date: 2:11:55 PM, Wednesday, July 07, 2010
Message:
Some preparation for accelerating other paint modes than sculpt

* Replaced Object.sculpt with Object.paint. This new PaintSession type for now 
just contains the PBVH so it can be built more or less the same for different 
paint modes. It also contains the old SculptSession data.
* Removed a couple of unused fields from SculptSession.
* Changed a lot of sculpt functions to pass around the Object rather than 
SculptSession; made sense anyway because we added an Object field to 
SculptSession to work around that problem.
* There should be no visible changes from this commit.

** jwilkins:
** this took considerable effort to merge
** deformed mesh sculpting probably needs to be ported into deformed mesh 
painting, but I left it out for now
** will wait on deformed meshes until I see exactly what needs to be done for it

Modified Paths:
--
branches/soc-2011-onion/source/blender/blenkernel/BKE_paint.h
branches/soc-2011-onion/source/blender/blenkernel/intern/DerivedMesh.c
branches/soc-2011-onion/source/blender/blenkernel/intern/cdderivedmesh.c
branches/soc-2011-onion/source/blender/blenkernel/intern/multires.c
branches/soc-2011-onion/source/blender/blenkernel/intern/object.c
branches/soc-2011-onion/source/blender/blenkernel/intern/paint.c
branches/soc-2011-onion/source/blender/blenkernel/intern/subsurf_ccg.c
branches/soc-2011-onion/source/blender/blenloader/intern/readfile.c
branches/soc-2011-onion/source/blender/editors/include/ED_sculpt.h
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_mask.c
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_stroke.c
branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt.c
branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt_undo.c
branches/soc-2011-onion/source/blender/editors/space_view3d/drawobject.c
branches/soc-2011-onion/source/blender/makesdna/DNA_object_types.h
branches/soc-2011-onion/source/blender/modifiers/intern/MOD_multires.c

Property Changed:

branches/soc-2011-onion/


Property changes on: branches/soc-2011-onion
___
Modified: svn:mergeinfo
   - /branches/soc-2010-jwilkins:28499-37009
/branches/soc-2010-nicolasbishop:28448-29913
/trunk/blender:36833-37206
   + /branches/soc-2010-jwilkins:28499-37009
/branches/soc-2010-nicolasbishop:28448-29913,30093
/trunk/blender:36833-37206

Modified: branches/soc-2011-onion/source/blender/blenkernel/BKE_paint.h
===
--- branches/soc-2011-onion/source/blender/blenkernel/BKE_paint.h   
2011-06-06 00:48:10 UTC (rev 37233)
+++ branches/soc-2011-onion/source/blender/blenkernel/BKE_paint.h   
2011-06-06 03:20:27 UTC (rev 37234)
@@ -62,8 +62,6 @@
 
 void paint_refresh_mask_display(struct Object *ob);
 
-/* Session data (mode-specific) */
-
 typedef struct SculptSession {
/* Mesh data (not copied) can come either directly from a Mesh, or from 
a MultiresDM */
struct MultiresModifierData *multires; /* Special handling for multires 
meshes */
@@ -76,18 +74,12 @@
/* Mesh connectivity */
struct ListBase *fmap;
 
-   /* PBVH acceleration structure */
-   struct PBVH *pbvh;
-
-   /* Paiting on deformed mesh */
+   /* Painting on deformed mesh */
int modifiers_active; /* object is deformed with some modifiers */
float (*orig_cos)[3]; /* coords of undeformed mesh */
float (*deform_cos)[3]; /* coords of deformed mesh but without stroke 
displacement */
float (*deform_imats)[3][3]; /* crazyspace deformation matricies */
 
-   /* Partial redraw */
-   int partial_redraw;
-
/* Area hiding */
ListBase hidden_areas;

@@ -101,6 +93,18 @@
struct StrokeCache *cache;
 } SculptSession;
 
-void free_sculptsession(struct Object *ob);
+typedef struct PaintSession {
+   /* mode-specific data (just sculpt for now */
+   SculptSession *sculpt;
 
+   /* PBVH acceleration structure */
+   struct PBVH *pbvh;
+
+   /* Partial redraw */
+   int partial_redraw;
+} PaintSession;
+
+void create_paintsession(struct Object *ob);
+void free_paintsession(struct Object *ob);
+
 #endif

Modified: branches/soc-2011-onion/source/blender/blenkernel/intern/DerivedMesh.c
===
--- branches/soc-2011-onion/source/blender/blenkernel/intern/DerivedMesh.c  
2011-06-06 00:48:10 UTC (rev 37233)
+++ branches/soc-2011-onion/source/blender/blenkernel/intern/DerivedMesh.c  
2011-06-06 03:20:27 UTC 

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37235] trunk/blender/source/blender/ editors: Resolve 2 theme issues

2011-06-05 Thread Campbell Barton
Revision: 37235
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37235
Author:   campbellbarton
Date: 2011-06-06 03:53:22 + (Mon, 06 Jun 2011)
Log Message:
---
Resolve 2 theme issues
[#27056] default active and selected colors need to be visually different
[#27584] Please change sharpness/seam color

Modified Paths:
--
trunk/blender/source/blender/editors/datafiles/startup.blend.c
trunk/blender/source/blender/editors/interface/resources.c

Modified: trunk/blender/source/blender/editors/datafiles/startup.blend.c
===
--- trunk/blender/source/blender/editors/datafiles/startup.blend.c  
2011-06-06 03:20:27 UTC (rev 37234)
+++ trunk/blender/source/blender/editors/datafiles/startup.blend.c  
2011-06-06 03:53:22 UTC (rev 37235)
@@ -8854,8 +8854,8 @@
   0,  0,  0,  0,  0,  0,  0,255,255,255,255,255,114,114,114,255,  0,  0,  
0,255,  0,  0,  0,255,255,255,255,255,114,114,114,255,
   0,  0,  0,255,  0,  0,  0,255,255,255,255,255,165,165,165,255,  0,  0,  
0,255,  0,  0,  0,255,255,255,255,255,165,165,165,127,
   0,  0,  0,255,  0,  0,  
0,255,255,255,255,255,160,160,160,100,127,112,112,100,  0,  0,  0,  0, 64, 64, 
64,255,  0,  0,  0,255,
-241, 88,  0,255,  0,  0,  0, 40,255,140, 25,255,  8, 48,  8,255, 85,187, 
85,255,255,255,255,255,  0,  0,  0,255,255,133,  0,255,
-  0,  0,  0,255,255,160,  0,255,219, 37, 18,255,255, 32, 32,255, 75, 75, 
75,255,204,  0,153,255,  0,  0,  0, 18,255,133,  0, 60,
+241, 88,  0,255,  0,  0,  0, 40,255,170, 64,255,  8, 48,  8,255, 85,187, 
85,255,255,255,255,255,  0,  0,  0,255,255,133,  0,255,
+  0,  0,  0,255,255,160,  0,255,219, 37, 18,255,32, 255,255,255, 75, 75, 
75,255,204,  0,153,255,  0,  0,  0, 18,255,133,  0, 60,
 255,133,  0,255, 32,  0,  0,255,  0, 32,  0,255,  0,  0,128,255,  0,  0,  0,  
0, 34,221,221,255, 35, 97,221,255,200,200,200,255,
  80,200,255, 80,  0,  0,  0,  0,  0,  0,  0,  0, 96,192, 64,255,144,144,  
0,255,128, 48, 96,255,219, 37, 18,255,240,255, 64,255,
 240,144,160,255,255,255,255,255,  0,  0,  0,255,144,144,  0,255, 64,144, 
48,255,128, 48, 96,255,  0,  0,  0,255,240,255, 64,255,

Modified: trunk/blender/source/blender/editors/interface/resources.c
===
--- trunk/blender/source/blender/editors/interface/resources.c  2011-06-06 
03:20:27 UTC (rev 37234)
+++ trunk/blender/source/blender/editors/interface/resources.c  2011-06-06 
03:53:22 UTC (rev 37235)
@@ -585,7 +585,7 @@
SETCOL(btheme-tv3d.wire,   0x0, 0x0, 0x0, 255);
SETCOL(btheme-tv3d.lamp,   0, 0, 0, 40);
SETCOL(btheme-tv3d.select, 241, 88, 0, 255);
-   SETCOL(btheme-tv3d.active, 255, 140, 25, 255);
+   SETCOL(btheme-tv3d.active, 255, 170, 64, 255);
SETCOL(btheme-tv3d.group,  8, 48, 8, 255);
SETCOL(btheme-tv3d.group_active, 85, 187, 85, 255);
SETCOL(btheme-tv3d.transform, 0xff, 0xff, 0xff, 255);
@@ -604,7 +604,7 @@
SETCOL(btheme-tv3d.face_dot, 255, 133, 0, 255);
SETCOL(btheme-tv3d.editmesh_active, 255, 255, 255, 128);
SETCOLF(btheme-tv3d.edge_crease, 0.8, 0, 0.6, 1.0);
-   SETCOL(btheme-tv3d.edge_sharp, 255, 32, 32, 255);
+   SETCOL(btheme-tv3d.edge_sharp, 0, 255, 255, 255);
SETCOL(btheme-tv3d.header_text, 0, 0, 0, 255);
SETCOL(btheme-tv3d.header_text_hi, 255, 255, 255, 255);
SETCOL(btheme-tv3d.button_text, 0, 0, 0, 255);

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37236] branches/soc-2011-onion/source/ blender/editors/sculpt_paint/paint_stroke.c: null pointer checks

2011-06-05 Thread Jason Wilkins
Revision: 37236
  
http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37236
Author:   jwilkins
Date: 2011-06-06 03:53:38 + (Mon, 06 Jun 2011)
Log Message:
---
null pointer checks

Modified Paths:
--
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_stroke.c

Modified: 
branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_stroke.c
===
--- branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_stroke.c  
2011-06-06 03:53:22 UTC (rev 37235)
+++ branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_stroke.c  
2011-06-06 03:53:38 UTC (rev 37236)
@@ -1258,7 +1258,7 @@
 
/* TODO: as sculpt and other paint modes are unified, this
   special mode of drawing will go away */
-   if (vc.obact-paint-sculpt) {
+   if (vc.obact-paint  vc.obact-paint-sculpt) {
Sculpt *sd = CTX_data_tool_settings(C)-sculpt;
 
int pixel_radius, viewport[4];
@@ -1555,7 +1555,7 @@
 
/* TODO: as sculpt and other paint modes are unified, this
   separation will go away */
-   if(stroke-vc.obact-paint-sculpt) {
+   if(stroke-vc.obact-paint  stroke-vc.obact-paint-sculpt) {
float delta[3];
 
brush_jitter_pos(brush, mouse_in, mouse);

___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs