[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [28530] branches/soc-2010-kwk: merge 28476 :28528
Konrad Kleine
konrad at konradwilhelm.de
Sat May 1 21:00:44 CEST 2010
Revision: 28530
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=28530
Author: kwk
Date: 2010-05-01 21:00:44 +0200 (Sat, 01 May 2010)
Log Message:
-----------
merge 28476:28528
Modified Paths:
--------------
branches/soc-2010-kwk/intern/guardedalloc/MEM_guardedalloc.h
branches/soc-2010-kwk/intern/guardedalloc/intern/mallocn.c
branches/soc-2010-kwk/projectfiles_vc9/blender/editors/ED_editors.vcproj
branches/soc-2010-kwk/release/scripts/io/netrender/client.py
branches/soc-2010-kwk/release/scripts/io/netrender/master.py
branches/soc-2010-kwk/release/scripts/io/netrender/master_html.py
branches/soc-2010-kwk/release/scripts/io/netrender/model.py
branches/soc-2010-kwk/release/scripts/io/netrender/netrender.css
branches/soc-2010-kwk/release/scripts/io/netrender/slave.py
branches/soc-2010-kwk/release/scripts/io/netrender/ui.py
branches/soc-2010-kwk/release/scripts/io/netrender/utils.py
branches/soc-2010-kwk/release/scripts/modules/graphviz_export.py
branches/soc-2010-kwk/release/scripts/op/uvcalc_smart_project.py
branches/soc-2010-kwk/release/scripts/ui/space_userpref.py
branches/soc-2010-kwk/release/scripts/ui/space_view3d.py
branches/soc-2010-kwk/source/blender/blenkernel/BKE_constraint.h
branches/soc-2010-kwk/source/blender/blenkernel/intern/action.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/armature.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/blender.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/brush.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/constraint.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/ipo.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/library.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/node.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/object.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/pointcache.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/sequencer.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/smoke.c
branches/soc-2010-kwk/source/blender/blenkernel/intern/texture.c
branches/soc-2010-kwk/source/blender/blenloader/intern/readfile.c
branches/soc-2010-kwk/source/blender/editors/animation/anim_channels_defines.c
branches/soc-2010-kwk/source/blender/editors/armature/poseobject.c
branches/soc-2010-kwk/source/blender/editors/curve/editcurve.c
branches/soc-2010-kwk/source/blender/editors/datafiles/B.blend.c
branches/soc-2010-kwk/source/blender/editors/gpencil/drawgpencil.c
branches/soc-2010-kwk/source/blender/editors/include/ED_gpencil.h
branches/soc-2010-kwk/source/blender/editors/include/ED_physics.h
branches/soc-2010-kwk/source/blender/editors/include/UI_resources.h
branches/soc-2010-kwk/source/blender/editors/interface/interface_handlers.c
branches/soc-2010-kwk/source/blender/editors/interface/interface_templates.c
branches/soc-2010-kwk/source/blender/editors/interface/resources.c
branches/soc-2010-kwk/source/blender/editors/object/object_constraint.c
branches/soc-2010-kwk/source/blender/editors/object/object_edit.c
branches/soc-2010-kwk/source/blender/editors/object/object_select.c
branches/soc-2010-kwk/source/blender/editors/physics/particle_edit.c
branches/soc-2010-kwk/source/blender/editors/physics/physics_intern.h
branches/soc-2010-kwk/source/blender/editors/physics/physics_ops.c
branches/soc-2010-kwk/source/blender/editors/space_api/spacetypes.c
branches/soc-2010-kwk/source/blender/editors/space_file/filelist.c
branches/soc-2010-kwk/source/blender/editors/space_file/space_file.c
branches/soc-2010-kwk/source/blender/editors/space_image/image_draw.c
branches/soc-2010-kwk/source/blender/editors/space_logic/logic_intern.h
branches/soc-2010-kwk/source/blender/editors/space_logic/logic_window.c
branches/soc-2010-kwk/source/blender/editors/space_nla/nla_draw.c
branches/soc-2010-kwk/source/blender/editors/space_node/node_draw.c
branches/soc-2010-kwk/source/blender/editors/space_sequencer/sequencer_draw.c
branches/soc-2010-kwk/source/blender/editors/space_view3d/drawobject.c
branches/soc-2010-kwk/source/blender/editors/space_view3d/drawvolume.c
branches/soc-2010-kwk/source/blender/editors/space_view3d/view3d_draw.c
branches/soc-2010-kwk/source/blender/editors/space_view3d/view3d_header.c
branches/soc-2010-kwk/source/blender/editors/space_view3d/view3d_select.c
branches/soc-2010-kwk/source/blender/makesdna/DNA_curve_types.h
branches/soc-2010-kwk/source/blender/makesdna/DNA_userdef_types.h
branches/soc-2010-kwk/source/blender/makesrna/RNA_access.h
branches/soc-2010-kwk/source/blender/makesrna/RNA_enum_types.h
branches/soc-2010-kwk/source/blender/makesrna/intern/rna_fcurve.c
branches/soc-2010-kwk/source/blender/makesrna/intern/rna_object.c
branches/soc-2010-kwk/source/blender/makesrna/intern/rna_sensor.c
branches/soc-2010-kwk/source/blender/makesrna/intern/rna_space.c
branches/soc-2010-kwk/source/blender/makesrna/intern/rna_userdef.c
branches/soc-2010-kwk/source/blender/windowmanager/intern/wm_files.c
branches/soc-2010-kwk/source/creator/creator.c
branches/soc-2010-kwk/source/gameengine/Converter/BL_ArmatureObject.cpp
Added Paths:
-----------
branches/soc-2010-kwk/source/blender/editors/include/ED_logic.h
branches/soc-2010-kwk/source/blender/editors/space_logic/logic_ops.c
Modified: branches/soc-2010-kwk/intern/guardedalloc/MEM_guardedalloc.h
===================================================================
--- branches/soc-2010-kwk/intern/guardedalloc/MEM_guardedalloc.h 2010-05-01 16:18:05 UTC (rev 28529)
+++ branches/soc-2010-kwk/intern/guardedalloc/MEM_guardedalloc.h 2010-05-01 19:00:44 UTC (rev 28530)
@@ -66,7 +66,7 @@
/** Returns the lenght of the allocated memory segment pointed at
* by vmemh. If the pointer was not previously allocated by this
* module, the result is undefined.*/
- int MEM_allocN_len(void *vmemh);
+ size_t MEM_allocN_len(void *vmemh);
/**
* Release memory previously allocatred by this module.
@@ -89,23 +89,23 @@
* allocated block, the old one is freed. this is not as optimized
* as a system realloc but just makes a new allocation and copies
* over from existing memory. */
- void *MEM_reallocN(void *vmemh, unsigned int len);
+ void *MEM_reallocN(void *vmemh, size_t len);
/**
* Allocate a block of memory of size len, with tag name str. The
* memory is cleared. The name must be static, because only a
* pointer to it is stored ! */
- void *MEM_callocN(unsigned int len, const char * str);
+ void *MEM_callocN(size_t len, const char * str);
/** Allocate a block of memory of size len, with tag name str. The
* name must be a static, because only a pointer to it is stored !
* */
- void *MEM_mallocN(unsigned int len, const char * str);
+ void *MEM_mallocN(size_t len, const char * str);
/** Same as callocN, clears memory and uses mmap (disk cached) if supported.
Can be free'd with MEM_freeN as usual.
* */
- void *MEM_mapallocN(unsigned int len, const char * str);
+ void *MEM_mapallocN(size_t len, const char * str);
/** Print a list of the names and sizes of all allocated memory
* blocks. as a python dict for easy investigation */
Modified: branches/soc-2010-kwk/intern/guardedalloc/intern/mallocn.c
===================================================================
--- branches/soc-2010-kwk/intern/guardedalloc/intern/mallocn.c 2010-05-01 16:18:05 UTC (rev 28529)
+++ branches/soc-2010-kwk/intern/guardedalloc/intern/mallocn.c 2010-05-01 19:00:44 UTC (rev 28530)
@@ -36,13 +36,20 @@
#include <stdlib.h>
#include <string.h> /* memcpy */
#include <stdarg.h>
+#include <sys/types.h>
+/* Blame Microsoft for LLP64 and no inttypes.h, quick workaround needed: */
+#if defined(WIN64)
+#define SIZET_FORMAT "%I64u"
+#define SIZET_ARG(a) ((unsigned long long)(a))
+#else
+#define SIZET_FORMAT "%lu"
+#define SIZET_ARG(a) ((unsigned long)(a))
+#endif
/* mmap exception */
#if defined(WIN32)
-#include <sys/types.h>
#include "mmap_win.h"
#else
-#include <sys/types.h>
#include <sys/mman.h>
#endif
@@ -82,11 +89,7 @@
/* note: keep this struct aligned (e.g., irix/gcc) - Hos */
typedef struct MemHead {
int tag1;
-#if defined(WIN64)
- unsigned long long len;
-#else
- unsigned long len;
-#endif
+ size_t len;
struct MemHead *next,*prev;
const char * name;
const char * nextname;
@@ -217,7 +220,7 @@
malloc_debug_memset= 1;
}
-int MEM_allocN_len(void *vmemh)
+size_t MEM_allocN_len(void *vmemh)
{
if (vmemh) {
MemHead *memh= vmemh;
@@ -249,7 +252,7 @@
return newp;
}
-void *MEM_reallocN(void *vmemh, unsigned int len)
+void *MEM_reallocN(void *vmemh, size_t len)
{
void *newp= NULL;
@@ -271,7 +274,7 @@
return newp;
}
-static void make_memhead_header(MemHead *memh, unsigned int len, const char *str)
+static void make_memhead_header(MemHead *memh, size_t len, const char *str)
{
MemTail *memt;
@@ -292,7 +295,7 @@
mem_in_use += len;
}
-void *MEM_mallocN(unsigned int len, const char *str)
+void *MEM_mallocN(size_t len, const char *str)
{
MemHead *memh;
@@ -316,11 +319,11 @@
return (++memh);
}
mem_unlock_thread();
- print_error("Malloc returns nill: len=%d in %s, total %u\n",len, str, mem_in_use);
+ print_error("Malloc returns null: len=" SIZET_FORMAT " in %s, total %u\n", SIZET_ARG(len), str, mem_in_use);
return NULL;
}
-void *MEM_callocN(unsigned int len, const char *str)
+void *MEM_callocN(size_t len, const char *str)
{
MemHead *memh;
@@ -341,12 +344,12 @@
return (++memh);
}
mem_unlock_thread();
- print_error("Calloc returns nill: len=%d in %s, total %u\n",len, str, mem_in_use);
+ print_error("Calloc returns null: len=" SIZET_FORMAT " in %s, total %u\n", SIZET_ARG(len), str, mem_in_use);
return 0;
}
/* note; mmap returns zero'd memory */
-void *MEM_mapallocN(unsigned int len, const char *str)
+void *MEM_mapallocN(size_t len, const char *str)
{
MemHead *memh;
@@ -384,7 +387,7 @@
}
else {
mem_unlock_thread();
- print_error("Mapalloc returns nill, fallback to regular malloc: len=%d in %s, total %u\n",len, str, mmap_in_use);
+ print_error("Mapalloc returns null, fallback to regular malloc: len=" SIZET_FORMAT " in %s, total %u\n", SIZET_ARG(len), str, mmap_in_use);
return MEM_callocN(len, str);
}
}
@@ -496,12 +499,12 @@
}
while(membl) {
if (pydict) {
- fprintf(stderr, "{'len':%i, 'name':'''%s''', 'pointer':'%p'},\\\n", membl->len, membl->name, membl+1);
+ fprintf(stderr, "{'len':" SIZET_FORMAT ", 'name':'''%s''', 'pointer':'%p'},\\\n", SIZET_ARG(membl->len), membl->name, membl+1);
} else {
#ifdef DEBUG_MEMCOUNTER
- print_error("%s len: %d %p, count: %d\n",membl->name,membl->len, membl+1, membl->_count);
+ print_error("%s len: " SIZET_FORMAT " %p, count: %d\n", membl->name, SIZET_ARG(membl->len), membl+1, membl->_count);
#else
- print_error("%s len: %d %p\n",membl->name,membl->len, membl+1);
+ print_error("%s len: " SIZET_FORMAT " %p\n", membl->name, SIZET_ARG(membl->len), membl+1);
#endif
}
if(membl->next)
Modified: branches/soc-2010-kwk/projectfiles_vc9/blender/editors/ED_editors.vcproj
===================================================================
--- branches/soc-2010-kwk/projectfiles_vc9/blender/editors/ED_editors.vcproj 2010-05-01 16:18:05 UTC (rev 28529)
+++ branches/soc-2010-kwk/projectfiles_vc9/blender/editors/ED_editors.vcproj 2010-05-01 19:00:44 UTC (rev 28530)
@@ -235,6 +235,10 @@
>
</File>
<File
+ RelativePath="..\..\..\source\blender\editors\include\ED_logic.h"
+ >
+ </File>
+ <File
RelativePath="..\..\..\source\blender\editors\include\ED_markers.h"
>
</File>
@@ -1476,6 +1480,10 @@
>
</File>
<File
+ RelativePath="..\..\..\source\blender\editors\space_logic\logic_ops.c"
+ >
+ </File>
+ <File
RelativePath="..\..\..\source\blender\editors\space_logic\logic_window.c"
>
</File>
Modified: branches/soc-2010-kwk/release/scripts/io/netrender/client.py
===================================================================
--- branches/soc-2010-kwk/release/scripts/io/netrender/client.py 2010-05-01 16:18:05 UTC (rev 28529)
+++ branches/soc-2010-kwk/release/scripts/io/netrender/client.py 2010-05-01 19:00:44 UTC (rev 28530)
@@ -125,6 +125,10 @@
file_path = bpy.utils.expandpath(image.filename)
if os.path.exists(file_path):
job.addFile(file_path)
+
+ tex_path = os.path.splitext(file_path)[0] + ".tex"
+ if os.path.exists(tex_path):
+ job.addFile(tex_path)
###########################
# FLUID + POINT CACHE
@@ -144,6 +148,9 @@
addPointCache(job, object, modifier.domain_settings.point_cache_low, default_path)
if modifier.domain_settings.highres:
addPointCache(job, object, modifier.domain_settings.point_cache_high, default_path)
+ elif modifier.type == "MULTIRES" and modifier.external:
+ file_path = bpy.utils.expandpath(modifier.filename)
+ job.addFile(file_path)
# particles modifier are stupid and don't contain data
# we have to go through the object property
Modified: branches/soc-2010-kwk/release/scripts/io/netrender/master.py
===================================================================
--- branches/soc-2010-kwk/release/scripts/io/netrender/master.py 2010-05-01 16:18:05 UTC (rev 28529)
+++ branches/soc-2010-kwk/release/scripts/io/netrender/master.py 2010-05-01 19:00:44 UTC (rev 28530)
@@ -27,12 +27,16 @@
import netrender.master_html
class MRenderFile(netrender.model.RenderFile):
- def __init__(self, filepath, index, start, end):
- super().__init__(filepath, index, start, end)
+ def __init__(self, filepath, index, start, end, signature):
+ super().__init__(filepath, index, start, end, signature)
self.found = False
def test(self):
self.found = os.path.exists(self.filepath)
+ if self.found:
+ found_signature = hashFile(self.filepath)
+ self.found = self.signature == found_signature
+
return self.found
@@ -74,7 +78,7 @@
# special server properties
self.last_update = 0
self.save_path = ""
- self.files = [MRenderFile(rfile.filepath, rfile.index, rfile.start, rfile.end) for rfile in job_info.files]
+ self.files = [MRenderFile(rfile.filepath, rfile.index, rfile.start, rfile.end, rfile.signature) for rfile in job_info.files]
self.resolution = None
@@ -716,7 +720,7 @@
buf = self.rfile.read(length)
# add same temp file + renames as slave
-
+
f = open(file_path, "wb")
f.write(buf)
f.close()
@@ -875,7 +879,7 @@
self.job_id = 0
self.path = path + "master_" + str(os.getpid()) + os.sep
- self.slave_timeout = 30 # 30 mins: need a parameter for that
+ self.slave_timeout = 5 # 5 mins: need a parameter for that
self.balancer = netrender.balancing.Balancer()
self.balancer.addRule(netrender.balancing.RatingUsageByCategory(self.getJobs))
Modified: branches/soc-2010-kwk/release/scripts/io/netrender/master_html.py
===================================================================
--- branches/soc-2010-kwk/release/scripts/io/netrender/master_html.py 2010-05-01 16:18:05 UTC (rev 28529)
+++ branches/soc-2010-kwk/release/scripts/io/netrender/master_html.py 2010-05-01 19:00:44 UTC (rev 28530)
@@ -106,53 +106,6 @@
handler.send_head(content = "text/html")
head("NetRender")
- output("<h2>Master</h2>")
-
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list