synched with trunk at revision 30243
authorNick Samarin <nicks1987@bigmir.net>
Wed, 14 Jul 2010 07:35:39 +0000 (07:35 +0000)
committerNick Samarin <nicks1987@bigmir.net>
Wed, 14 Jul 2010 07:35:39 +0000 (07:35 +0000)
741 files changed:
CMake/macros.cmake [deleted file]
CMakeLists.txt
SConstruct
build_files/cmake/macros.cmake [new file with mode: 0644]
build_files/make/example_scripts/linux_nanmakefiles.sh [new file with mode: 0755]
build_files/make/example_scripts/macos_nanmakefiles.sh [new file with mode: 0755]
build_files/make/example_scripts/sunos_nanmakefiles.sh [new file with mode: 0755]
build_files/scons/config/aix4-config.py [moved from config/aix4-config.py with 96% similarity]
build_files/scons/config/darwin-config.py [moved from config/darwin-config.py with 97% similarity]
build_files/scons/config/irix6-config.py [moved from config/irix6-config.py with 100% similarity]
build_files/scons/config/linux2-config.py [moved from config/linux2-config.py with 98% similarity]
build_files/scons/config/linuxcross-config.py [moved from config/linuxcross-config.py with 95% similarity]
build_files/scons/config/openbsd3-config.py [moved from config/openbsd3-config.py with 100% similarity]
build_files/scons/config/sunos5-config.py [moved from config/sunos5-config.py with 100% similarity]
build_files/scons/config/win32-mingw-config.py [moved from config/win32-mingw-config.py with 99% similarity]
build_files/scons/config/win32-vc-config.py [moved from config/win32-vc-config.py with 98% similarity]
build_files/scons/config/win64-vc-config.py [moved from config/win64-vc-config.py with 98% similarity]
build_files/scons/tools/Blender.py [moved from tools/Blender.py with 94% similarity]
build_files/scons/tools/__init__.py [moved from tools/__init__.py with 100% similarity]
build_files/scons/tools/bcolors.py [moved from tools/bcolors.py with 100% similarity]
build_files/scons/tools/btools.py [moved from tools/btools.py with 78% similarity]
build_files/scons/tools/crossmingw.py [moved from tools/crossmingw.py with 100% similarity]
build_files/scons/tools/mstoolkit.py [moved from tools/mstoolkit.py with 100% similarity]
doc/blender.1 [new file with mode: 0644]
doc/blender.1.py [new file with mode: 0644]
extern/glew/include/GL/glew.h
extern/glew/src/glew.c
intern/ghost/CMakeLists.txt
intern/ghost/GHOST_C-api.h
intern/ghost/GHOST_ISystem.h
intern/ghost/GHOST_IWindow.h
intern/ghost/GHOST_Path-api.h [new file with mode: 0644]
intern/ghost/intern/GHOST_C-api.cpp
intern/ghost/intern/GHOST_Path-api.cpp [new file with mode: 0644]
intern/ghost/intern/GHOST_System.h
intern/ghost/intern/GHOST_SystemCarbon.cpp
intern/ghost/intern/GHOST_SystemCarbon.h
intern/ghost/intern/GHOST_SystemCocoa.h
intern/ghost/intern/GHOST_SystemCocoa.mm
intern/ghost/intern/GHOST_SystemWin32.cpp
intern/ghost/intern/GHOST_SystemWin32.h
intern/ghost/intern/GHOST_SystemX11.cpp
intern/ghost/intern/GHOST_SystemX11.h
intern/ghost/intern/GHOST_Window.cpp
intern/ghost/intern/GHOST_Window.h
intern/ghost/intern/GHOST_WindowCocoa.h
intern/ghost/intern/GHOST_WindowCocoa.mm
intern/ghost/intern/GHOST_WindowWin32.cpp
intern/ghost/intern/GHOST_WindowWin32.h
intern/ghost/intern/GHOST_WindowX11.cpp
intern/ghost/intern/GHOST_WindowX11.h
intern/ghost/intern/Makefile
intern/ghost/make/msvc_9_0/ghost.vcproj
intern/string/STR_String.h
projectfiles_vc9/blender/blender.vcproj
projectfiles_vc9/blender/blenlib/BLI_blenlib.vcproj
projectfiles_vc9/blender/makesrna/RNA_makesrna.vcproj
release/scripts/io/engine_render_pov.py
release/scripts/io/export_3ds.py
release/scripts/io/export_fbx.py
release/scripts/io/export_mdd.py
release/scripts/io/export_obj.py
release/scripts/io/export_ply.py
release/scripts/io/export_x3d.py
release/scripts/io/import_anim_bvh.py
release/scripts/io/import_scene_3ds.py
release/scripts/io/import_scene_obj.py
release/scripts/io/import_shape_mdd.py
release/scripts/io/netrender/client.py
release/scripts/io/netrender/master.py
release/scripts/io/netrender/operators.py
release/scripts/io/netrender/repath.py
release/scripts/io/netrender/ui.py
release/scripts/io/netrender/utils.py
release/scripts/modules/add_object_utils.py
release/scripts/modules/blend_render_info.py [new file with mode: 0755]
release/scripts/modules/bpy/utils.py
release/scripts/modules/bpy_types.py
release/scripts/modules/graphviz_export.py
release/scripts/modules/rigify/__init__.py
release/scripts/modules/rna_info.py
release/scripts/modules/rna_prop_ui.py
release/scripts/op/console_python.py
release/scripts/op/image.py
release/scripts/op/object.py
release/scripts/op/object_align.py
release/scripts/op/presets.py
release/scripts/op/sequencer.py
release/scripts/op/uv.py
release/scripts/op/uvcalc_smart_project.py
release/scripts/op/wm.py
release/scripts/presets/cloth/cotton.py
release/scripts/presets/cloth/denim.py
release/scripts/presets/cloth/leather.py
release/scripts/presets/cloth/rubber.py
release/scripts/presets/cloth/silk.py
release/scripts/presets/ffmpeg/DV.py
release/scripts/presets/ffmpeg/DVD.py
release/scripts/presets/ffmpeg/SVCD.py
release/scripts/presets/ffmpeg/VCD.py
release/scripts/presets/ffmpeg/h264.py
release/scripts/presets/ffmpeg/theora.py
release/scripts/presets/ffmpeg/xvid.py
release/scripts/presets/interaction/maya.py
release/scripts/presets/render/DVCPRO_HD_1080p.py
release/scripts/presets/render/DVCPRO_HD_720p.py
release/scripts/presets/render/HDTV_1080p.py
release/scripts/presets/render/HDTV_720p.py
release/scripts/presets/render/HDV_1080p.py
release/scripts/presets/render/TV_NTSC_16_colon_9.py
release/scripts/presets/render/TV_NTSC_4_colon_3.py
release/scripts/presets/render/TV_PAL_16_colon_9.py
release/scripts/presets/render/TV_PAL_4_colon_3.py
release/scripts/presets/sss/apple.py
release/scripts/presets/sss/chicken.py
release/scripts/presets/sss/cream.py
release/scripts/presets/sss/ketchup.py
release/scripts/presets/sss/marble.py
release/scripts/presets/sss/potato.py
release/scripts/presets/sss/skim_milk.py
release/scripts/presets/sss/skin1.py
release/scripts/presets/sss/skin2.py
release/scripts/presets/sss/whole_milk.py
release/scripts/presets/sunsky/classic.py
release/scripts/presets/sunsky/desert.py
release/scripts/presets/sunsky/mountain.py
release/scripts/templates/operator.py
release/scripts/templates/operator_modal.py
release/scripts/templates/operator_modal_draw.py
release/scripts/templates/operator_modal_view3d.py
release/scripts/templates/operator_uv.py
release/scripts/ui/properties_data_armature.py
release/scripts/ui/properties_data_armature_rigify.py
release/scripts/ui/properties_data_curve.py
release/scripts/ui/properties_data_modifier.py
release/scripts/ui/properties_game.py
release/scripts/ui/properties_object.py
release/scripts/ui/properties_object_constraint.py
release/scripts/ui/properties_particle.py
release/scripts/ui/properties_physics_cloth.py
release/scripts/ui/properties_physics_common.py
release/scripts/ui/properties_physics_smoke.py
release/scripts/ui/properties_physics_softbody.py
release/scripts/ui/properties_render.py
release/scripts/ui/properties_scene.py
release/scripts/ui/properties_texture.py
release/scripts/ui/space_image.py
release/scripts/ui/space_info.py
release/scripts/ui/space_logic.py
release/scripts/ui/space_node.py
release/scripts/ui/space_sequencer.py
release/scripts/ui/space_text.py
release/scripts/ui/space_time.py
release/scripts/ui/space_userpref.py
release/scripts/ui/space_userpref_keymap.py
release/scripts/ui/space_view3d.py
release/scripts/ui/space_view3d_toolbar.py
release/windows/inno/blender.iss [deleted file]
release/windows/inno/copyright.txt [deleted file]
release/windows/inno/installer.bmp [deleted file]
release/windows/installer/00.checked.bmp [new file with mode: 0644]
release/windows/installer/00.header.bmp [moved from release/windows/inno/header.bmp with 100% similarity]
release/windows/installer/00.installer.ico [moved from release/windows/inno/installer.ico with 100% similarity]
release/windows/installer/00.sconsblender.nsi [new file with mode: 0644]
source/Makefile
source/blender/blenfont/intern/blf_lang.c
source/blender/blenkernel/BKE_customdata.h
source/blender/blenkernel/BKE_displist.h
source/blender/blenkernel/BKE_idprop.h
source/blender/blenkernel/BKE_image.h
source/blender/blenkernel/BKE_key.h
source/blender/blenkernel/BKE_lattice.h
source/blender/blenkernel/BKE_mball.h
source/blender/blenkernel/BKE_multires.h
source/blender/blenkernel/BKE_node.h
source/blender/blenkernel/BKE_paint.h
source/blender/blenkernel/BKE_report.h
source/blender/blenkernel/BKE_sca.h
source/blender/blenkernel/BKE_scene.h
source/blender/blenkernel/BKE_sequencer.h
source/blender/blenkernel/BKE_softbody.h
source/blender/blenkernel/BKE_subsurf.h
source/blender/blenkernel/BKE_texture.h
source/blender/blenkernel/CMakeLists.txt
source/blender/blenkernel/SConscript
source/blender/blenkernel/intern/CCGSubSurf.c
source/blender/blenkernel/intern/CCGSubSurf.h
source/blender/blenkernel/intern/DerivedMesh.c
source/blender/blenkernel/intern/action.c
source/blender/blenkernel/intern/anim.c
source/blender/blenkernel/intern/armature.c
source/blender/blenkernel/intern/blender.c
source/blender/blenkernel/intern/cdderivedmesh.c
source/blender/blenkernel/intern/collision.c
source/blender/blenkernel/intern/customdata.c
source/blender/blenkernel/intern/depsgraph.c
source/blender/blenkernel/intern/displist.c
source/blender/blenkernel/intern/effect.c
source/blender/blenkernel/intern/exotic.c
source/blender/blenkernel/intern/group.c
source/blender/blenkernel/intern/idprop.c
source/blender/blenkernel/intern/image.c
source/blender/blenkernel/intern/ipo.c
source/blender/blenkernel/intern/key.c
source/blender/blenkernel/intern/lattice.c
source/blender/blenkernel/intern/library.c
source/blender/blenkernel/intern/mball.c
source/blender/blenkernel/intern/mesh.c
source/blender/blenkernel/intern/multires.c
source/blender/blenkernel/intern/node.c
source/blender/blenkernel/intern/object.c
source/blender/blenkernel/intern/packedFile.c
source/blender/blenkernel/intern/particle.c
source/blender/blenkernel/intern/particle_system.c
source/blender/blenkernel/intern/pointcache.c
source/blender/blenkernel/intern/report.c
source/blender/blenkernel/intern/sca.c
source/blender/blenkernel/intern/scene.c
source/blender/blenkernel/intern/seqeffects.c
source/blender/blenkernel/intern/sequencer.c
source/blender/blenkernel/intern/shrinkwrap.c
source/blender/blenkernel/intern/softbody.c
source/blender/blenkernel/intern/sound.c
source/blender/blenkernel/intern/subsurf_ccg.c
source/blender/blenkernel/intern/text.c
source/blender/blenkernel/intern/texture.c
source/blender/blenlib/BLI_cpu.h [new file with mode: 0644]
source/blender/blenlib/BLI_fileops.h
source/blender/blenlib/BLI_linklist.h
source/blender/blenlib/BLI_math_base.h
source/blender/blenlib/BLI_math_inline.h
source/blender/blenlib/BLI_math_matrix.h
source/blender/blenlib/BLI_path_util.h
source/blender/blenlib/BLI_pbvh.h
source/blender/blenlib/BLI_rect.h
source/blender/blenlib/BLI_uvproject.h
source/blender/blenlib/intern/BLI_args.c
source/blender/blenlib/intern/BLI_bfile.c
source/blender/blenlib/intern/BLI_linklist.c
source/blender/blenlib/intern/bpath.c
source/blender/blenlib/intern/cpu.c [new file with mode: 0644]
source/blender/blenlib/intern/fileops.c
source/blender/blenlib/intern/math_geom.c
source/blender/blenlib/intern/math_matrix.c
source/blender/blenlib/intern/noise.c
source/blender/blenlib/intern/path_util.c
source/blender/blenlib/intern/pbvh.c
source/blender/blenlib/intern/rct.c
source/blender/blenlib/intern/threads.c
source/blender/blenlib/intern/uvproject.c
source/blender/blenloader/intern/readfile.c
source/blender/blenloader/intern/writefile.c
source/blender/collada/DocumentExporter.cpp
source/blender/collada/DocumentExporter.h
source/blender/collada/DocumentImporter.cpp
source/blender/collada/DocumentImporter.h
source/blender/collada/SConscript
source/blender/collada/collada.cpp
source/blender/collada/collada.h
source/blender/collada/collada_internal.h
source/blender/editors/CMakeLists.txt
source/blender/editors/animation/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/animation/anim_channels_defines.c
source/blender/editors/animation/anim_channels_edit.c
source/blender/editors/animation/anim_deps.c
source/blender/editors/animation/anim_filter.c
source/blender/editors/animation/anim_ops.c
source/blender/editors/animation/fmodifier_ui.c
source/blender/editors/animation/keyframes_draw.c
source/blender/editors/animation/keyframing.c
source/blender/editors/animation/keyingsets.c
source/blender/editors/armature/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/armature/Makefile
source/blender/editors/armature/SConscript
source/blender/editors/armature/armature_intern.h
source/blender/editors/armature/armature_ops.c
source/blender/editors/armature/editarmature_sketch.c
source/blender/editors/armature/meshlaplacian.c
source/blender/editors/armature/meshlaplacian.h
source/blender/editors/armature/poselib.c
source/blender/editors/curve/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/curve/curve_intern.h
source/blender/editors/curve/curve_ops.c
source/blender/editors/curve/editcurve.c
source/blender/editors/curve/editfont.c
source/blender/editors/datafiles/B.blend.c
source/blender/editors/datafiles/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/gpencil/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/gpencil/gpencil_paint.c
source/blender/editors/include/ED_anim_api.h
source/blender/editors/include/ED_armature.h
source/blender/editors/include/ED_keyframing.h
source/blender/editors/include/ED_object.h
source/blender/editors/include/ED_render.h
source/blender/editors/include/ED_screen.h
source/blender/editors/include/ED_screen_types.h
source/blender/editors/include/ED_view3d.h
source/blender/editors/include/UI_interface.h
source/blender/editors/interface/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/interface/interface_anim.c
source/blender/editors/interface/interface_handlers.c
source/blender/editors/interface/interface_icons.c
source/blender/editors/interface/interface_intern.h
source/blender/editors/interface/interface_layout.c
source/blender/editors/interface/interface_ops.c
source/blender/editors/interface/interface_panel.c
source/blender/editors/interface/interface_regions.c
source/blender/editors/interface/interface_templates.c
source/blender/editors/interface/interface_widgets.c
source/blender/editors/interface/view2d_ops.c
source/blender/editors/mesh/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/mesh/editmesh.c
source/blender/editors/mesh/editmesh_add.c
source/blender/editors/mesh/editmesh_mods.c
source/blender/editors/mesh/editmesh_tools.c
source/blender/editors/mesh/mesh_data.c
source/blender/editors/mesh/mesh_intern.h
source/blender/editors/mesh/mesh_ops.c
source/blender/editors/mesh/meshtools.c
source/blender/editors/metaball/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/metaball/mball_edit.c
source/blender/editors/object/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/object/object_add.c
source/blender/editors/object/object_constraint.c
source/blender/editors/object/object_edit.c
source/blender/editors/object/object_intern.h
source/blender/editors/object/object_modifier.c
source/blender/editors/object/object_ops.c
source/blender/editors/object/object_relations.c
source/blender/editors/object/object_transform.c
source/blender/editors/object/object_vgroup.c
source/blender/editors/physics/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/physics/particle_edit.c
source/blender/editors/physics/particle_object.c
source/blender/editors/physics/physics_fluid.c
source/blender/editors/physics/physics_pointcache.c
source/blender/editors/render/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/render/render_internal.c
source/blender/editors/render/render_opengl.c
source/blender/editors/render/render_preview.c
source/blender/editors/render/render_shading.c
source/blender/editors/screen/CMakeLists.txt
source/blender/editors/screen/SConscript
source/blender/editors/screen/area.c
source/blender/editors/screen/screen_context.c
source/blender/editors/screen/screen_edit.c
source/blender/editors/screen/screen_ops.c
source/blender/editors/screen/screendump.c
source/blender/editors/sculpt_paint/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/sculpt_paint/paint_image.c
source/blender/editors/sculpt_paint/paint_ops.c
source/blender/editors/sculpt_paint/paint_stroke.c
source/blender/editors/sculpt_paint/paint_vertex.c
source/blender/editors/sculpt_paint/sculpt.c
source/blender/editors/sculpt_paint/sculpt_intern.h
source/blender/editors/sound/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/sound/SConscript
source/blender/editors/sound/sound_ops.c
source/blender/editors/space_action/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_action/action_edit.c
source/blender/editors/space_action/action_select.c
source/blender/editors/space_action/space_action.c
source/blender/editors/space_api/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_api/SConscript
source/blender/editors/space_buttons/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_buttons/SConscript
source/blender/editors/space_buttons/buttons_ops.c
source/blender/editors/space_buttons/space_buttons.c
source/blender/editors/space_console/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_console/space_console.c
source/blender/editors/space_file/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_file/file_ops.c
source/blender/editors/space_file/file_panels.c
source/blender/editors/space_file/filelist.c
source/blender/editors/space_file/filesel.c
source/blender/editors/space_file/fsmenu.c
source/blender/editors/space_file/fsmenu.h
source/blender/editors/space_file/space_file.c
source/blender/editors/space_graph/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_graph/graph_edit.c
source/blender/editors/space_graph/graph_ops.c
source/blender/editors/space_graph/graph_select.c
source/blender/editors/space_graph/space_graph.c
source/blender/editors/space_image/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_image/SConscript
source/blender/editors/space_image/image_buttons.c
source/blender/editors/space_image/image_ops.c
source/blender/editors/space_image/space_image.c
source/blender/editors/space_info/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_info/SConscript
source/blender/editors/space_info/info_intern.h
source/blender/editors/space_info/info_ops.c
source/blender/editors/space_info/space_info.c
source/blender/editors/space_logic/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_logic/logic_ops.c
source/blender/editors/space_logic/logic_window.c
source/blender/editors/space_nla/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_nla/nla_channels.c
source/blender/editors/space_nla/nla_edit.c
source/blender/editors/space_nla/nla_select.c
source/blender/editors/space_node/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_node/drawnode.c
source/blender/editors/space_node/node_draw.c
source/blender/editors/space_node/node_edit.c
source/blender/editors/space_node/node_intern.h
source/blender/editors/space_node/node_ops.c
source/blender/editors/space_node/node_select.c
source/blender/editors/space_node/node_state.c
source/blender/editors/space_node/space_node.c
source/blender/editors/space_outliner/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_outliner/outliner.c
source/blender/editors/space_script/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_script/script_edit.c
source/blender/editors/space_script/script_intern.h
source/blender/editors/space_script/script_ops.c
source/blender/editors/space_script/space_script.c
source/blender/editors/space_sequencer/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_sequencer/sequencer_add.c
source/blender/editors/space_sequencer/sequencer_draw.c
source/blender/editors/space_sequencer/sequencer_edit.c
source/blender/editors/space_sequencer/sequencer_intern.h
source/blender/editors/space_sequencer/sequencer_ops.c
source/blender/editors/space_sequencer/sequencer_select.c
source/blender/editors/space_sequencer/space_sequencer.c
source/blender/editors/space_sound/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_text/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_text/space_text.c
source/blender/editors/space_text/text_draw.c
source/blender/editors/space_text/text_ops.c
source/blender/editors/space_time/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_time/space_time.c
source/blender/editors/space_userpref/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_userpref/SConscript
source/blender/editors/space_view3d/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/space_view3d/drawmesh.c
source/blender/editors/space_view3d/drawobject.c
source/blender/editors/space_view3d/space_view3d.c
source/blender/editors/space_view3d/view3d_draw.c
source/blender/editors/space_view3d/view3d_edit.c
source/blender/editors/space_view3d/view3d_header.c
source/blender/editors/space_view3d/view3d_intern.h
source/blender/editors/space_view3d/view3d_ops.c
source/blender/editors/space_view3d/view3d_select.c
source/blender/editors/space_view3d/view3d_snap.c
source/blender/editors/space_view3d/view3d_view.c
source/blender/editors/transform/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/transform/transform.c
source/blender/editors/transform/transform_conversions.c
source/blender/editors/transform/transform_generics.c
source/blender/editors/transform/transform_ops.c
source/blender/editors/transform/transform_snap.c
source/blender/editors/util/CMakeLists.txt [new file with mode: 0644]
source/blender/editors/util/ed_util.c
source/blender/editors/uvedit/CMakeLists.txt [new file with mode: 0644]
source/blender/gpu/GPU_extensions.h
source/blender/gpu/intern/gpu_buffers.c
source/blender/gpu/intern/gpu_extensions.c
source/blender/imbuf/IMB_imbuf.h
source/blender/imbuf/IMB_thumbs.h
source/blender/imbuf/intern/IMB_filetype.h
source/blender/imbuf/intern/anim.c
source/blender/imbuf/intern/divers.c
source/blender/imbuf/intern/filetype.c
source/blender/imbuf/intern/openexr/openexr_api.cpp
source/blender/imbuf/intern/targa.c
source/blender/imbuf/intern/thumbs.c
source/blender/imbuf/intern/thumbs_blend.c
source/blender/imbuf/intern/tiff.c
source/blender/makesdna/DNA_ID.h
source/blender/makesdna/DNA_action_types.h
source/blender/makesdna/DNA_armature_types.h
source/blender/makesdna/DNA_camera_types.h
source/blender/makesdna/DNA_lamp_types.h
source/blender/makesdna/DNA_modifier_types.h
source/blender/makesdna/DNA_node_types.h
source/blender/makesdna/DNA_object_types.h
source/blender/makesdna/DNA_scene_types.h
source/blender/makesdna/DNA_screen_types.h
source/blender/makesdna/DNA_sequence_types.h
source/blender/makesdna/DNA_space_types.h
source/blender/makesdna/DNA_texture_types.h
source/blender/makesdna/DNA_userdef_types.h
source/blender/makesdna/DNA_windowmanager_types.h
source/blender/makesrna/RNA_access.h
source/blender/makesrna/RNA_types.h
source/blender/makesrna/SConscript
source/blender/makesrna/intern/CMakeLists.txt
source/blender/makesrna/intern/makesrna.c
source/blender/makesrna/intern/rna_ID.c
source/blender/makesrna/intern/rna_access.c
source/blender/makesrna/intern/rna_action.c
source/blender/makesrna/intern/rna_actuator.c
source/blender/makesrna/intern/rna_actuator_api.c [new file with mode: 0644]
source/blender/makesrna/intern/rna_armature.c
source/blender/makesrna/intern/rna_boid.c
source/blender/makesrna/intern/rna_constraint.c
source/blender/makesrna/intern/rna_controller.c
source/blender/makesrna/intern/rna_controller_api.c [new file with mode: 0644]
source/blender/makesrna/intern/rna_curve.c
source/blender/makesrna/intern/rna_fcurve.c
source/blender/makesrna/intern/rna_group.c
source/blender/makesrna/intern/rna_image.c
source/blender/makesrna/intern/rna_image_api.c
source/blender/makesrna/intern/rna_internal.h
source/blender/makesrna/intern/rna_lamp.c
source/blender/makesrna/intern/rna_main.c
source/blender/makesrna/intern/rna_main_api.c
source/blender/makesrna/intern/rna_mesh.c
source/blender/makesrna/intern/rna_modifier.c
source/blender/makesrna/intern/rna_nodetree.c
source/blender/makesrna/intern/rna_object.c
source/blender/makesrna/intern/rna_object_api.c
source/blender/makesrna/intern/rna_object_force.c
source/blender/makesrna/intern/rna_particle.c
source/blender/makesrna/intern/rna_scene.c
source/blender/makesrna/intern/rna_screen.c
source/blender/makesrna/intern/rna_sculpt_paint.c
source/blender/makesrna/intern/rna_sensor.c
source/blender/makesrna/intern/rna_sensor_api.c [new file with mode: 0644]
source/blender/makesrna/intern/rna_sequencer.c
source/blender/makesrna/intern/rna_sequencer_api.c [new file with mode: 0644]
source/blender/makesrna/intern/rna_sound.c
source/blender/makesrna/intern/rna_space.c
source/blender/makesrna/intern/rna_text.c
source/blender/makesrna/intern/rna_texture.c
source/blender/makesrna/intern/rna_ui_api.c
source/blender/makesrna/intern/rna_userdef.c
source/blender/makesrna/intern/rna_vfont.c
source/blender/makesrna/intern/rna_wm.c
source/blender/makesrna/rna_cleanup/rna_booleans.txt [new file with mode: 0644]
source/blender/makesrna/rna_cleanup/rna_cleaner.py [new file with mode: 0755]
source/blender/modifiers/intern/MOD_build.c
source/blender/modifiers/intern/MOD_collision.c
source/blender/modifiers/intern/MOD_displace.c
source/blender/modifiers/intern/MOD_explode.c
source/blender/modifiers/intern/MOD_hook.c
source/blender/modifiers/intern/MOD_meshdeform.c
source/blender/modifiers/intern/MOD_multires.c
source/blender/modifiers/intern/MOD_screw.c
source/blender/modifiers/intern/MOD_solidify.c
source/blender/modifiers/intern/MOD_uvproject.c
source/blender/modifiers/intern/MOD_wave.c
source/blender/nodes/intern/CMP_nodes/CMP_colorbalance.c
source/blender/nodes/intern/CMP_nodes/CMP_defocus.c
source/blender/nodes/intern/CMP_nodes/CMP_outputFile.c
source/blender/nodes/intern/CMP_nodes/CMP_scale.c
source/blender/nodes/intern/CMP_nodes/CMP_texture.c
source/blender/python/doc/examples/bpy.data.py [new file with mode: 0644]
source/blender/python/doc/examples/mathutils.Vector.py
source/blender/python/doc/examples/mathutils.py
source/blender/python/doc/sphinx_doc_gen.py
source/blender/python/doc/sphinx_doc_gen.sh
source/blender/python/generic/bgl.c
source/blender/python/generic/blf_api.c
source/blender/python/generic/bpy_internal_import.c
source/blender/python/generic/bpy_internal_import.h
source/blender/python/generic/geometry.c
source/blender/python/generic/mathutils.c
source/blender/python/intern/bpy.c
source/blender/python/intern/bpy_driver.c
source/blender/python/intern/bpy_interface.c
source/blender/python/intern/bpy_props.c
source/blender/python/intern/bpy_props.h
source/blender/python/intern/bpy_rna.c
source/blender/readblenfile/intern/BLO_readblenfile.c
source/blender/render/CMakeLists.txt
source/blender/render/extern/include/RE_pipeline.h
source/blender/render/intern/include/render_types.h
source/blender/render/intern/include/texture.h
source/blender/render/intern/source/convertblender.c
source/blender/render/intern/source/imagetexture.c
source/blender/render/intern/source/pipeline.c
source/blender/render/intern/source/pointdensity.c
source/blender/render/intern/source/rayobject_instance.c
source/blender/render/intern/source/rayshade.c
source/blender/render/intern/source/texture.c
source/blender/render/intern/source/voxeldata.c
source/blender/windowmanager/WM_api.h
source/blender/windowmanager/WM_types.h
source/blender/windowmanager/intern/wm.c
source/blender/windowmanager/intern/wm_draw.c
source/blender/windowmanager/intern/wm_event_system.c
source/blender/windowmanager/intern/wm_files.c
source/blender/windowmanager/intern/wm_init_exit.c
source/blender/windowmanager/intern/wm_jobs.c
source/blender/windowmanager/intern/wm_keymap.c
source/blender/windowmanager/intern/wm_operators.c
source/blender/windowmanager/intern/wm_subwindow.c
source/blender/windowmanager/intern/wm_window.c
source/blender/windowmanager/wm_event_types.h
source/blender/windowmanager/wm_files.h
source/blenderplayer/bad_level_call_stubs/stubs.c
source/creator/CMakeLists.txt
source/creator/creator.c
source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
source/gameengine/BlenderRoutines/KX_BlenderCanvas.h
source/gameengine/BlenderRoutines/KX_BlenderInputDevice.h
source/gameengine/BlenderRoutines/KX_BlenderKeyboardDevice.h
source/gameengine/BlenderRoutines/KX_BlenderMouseDevice.h
source/gameengine/BlenderRoutines/KX_BlenderRenderTools.h
source/gameengine/BlenderRoutines/KX_BlenderSystem.h
source/gameengine/Converter/BL_BlenderDataConversion.cpp
source/gameengine/Converter/BL_DeformableGameObject.h
source/gameengine/Converter/BL_MeshDeformer.h
source/gameengine/Converter/BL_ModifierDeformer.h
source/gameengine/Converter/BL_ShapeDeformer.h
source/gameengine/Converter/BL_SkinDeformer.h
source/gameengine/Converter/BlenderWorldInfo.h
source/gameengine/Converter/KX_BlenderScalarInterpolator.h
source/gameengine/Converter/KX_BlenderSceneConverter.cpp
source/gameengine/Converter/KX_BlenderSceneConverter.h
source/gameengine/Converter/KX_SoftBodyDeformer.h
source/gameengine/Expressions/BoolValue.h
source/gameengine/Expressions/ConstExpr.h
source/gameengine/Expressions/EmptyValue.h
source/gameengine/Expressions/ErrorValue.h
source/gameengine/Expressions/Expression.h
source/gameengine/Expressions/FloatValue.h
source/gameengine/Expressions/IdentifierExpr.h
source/gameengine/Expressions/IfExpr.h
source/gameengine/Expressions/InputParser.h
source/gameengine/Expressions/IntValue.h
source/gameengine/Expressions/KX_HashedPtr.h
source/gameengine/Expressions/Operator1Expr.h
source/gameengine/Expressions/Operator2Expr.h
source/gameengine/Expressions/PyObjectPlus.h
source/gameengine/Expressions/StringValue.h
source/gameengine/Expressions/Value.h
source/gameengine/Expressions/VectorValue.h
source/gameengine/Expressions/VoidValue.h
source/gameengine/GameLogic/SCA_ActuatorEventManager.h
source/gameengine/GameLogic/SCA_AlwaysEventManager.h
source/gameengine/GameLogic/SCA_BasicEventManager.h
source/gameengine/GameLogic/SCA_EventManager.h
source/gameengine/GameLogic/SCA_ExpressionController.h
source/gameengine/GameLogic/SCA_IActuator.h
source/gameengine/GameLogic/SCA_IInputDevice.h
source/gameengine/GameLogic/SCA_IScene.h
source/gameengine/GameLogic/SCA_JoystickManager.h
source/gameengine/GameLogic/SCA_KeyboardManager.h
source/gameengine/GameLogic/SCA_LogicManager.h
source/gameengine/GameLogic/SCA_MouseManager.h
source/gameengine/GameLogic/SCA_PropertyEventManager.h
source/gameengine/GameLogic/SCA_PythonMouse.cpp
source/gameengine/GameLogic/SCA_RandomEventManager.h
source/gameengine/GameLogic/SCA_RandomNumberGenerator.h
source/gameengine/GameLogic/SCA_TimeEventManager.h
source/gameengine/Ketsji/BL_BlenderShader.h
source/gameengine/Ketsji/BL_Material.h
source/gameengine/Ketsji/BL_Shader.h
source/gameengine/Ketsji/BL_Texture.h
source/gameengine/Ketsji/KX_BlenderMaterial.h
source/gameengine/Ketsji/KX_BulletPhysicsController.h
source/gameengine/Ketsji/KX_CameraIpoSGController.h
source/gameengine/Ketsji/KX_ClientObjectInfo.h
source/gameengine/Ketsji/KX_Dome.h
source/gameengine/Ketsji/KX_EmptyObject.h
source/gameengine/Ketsji/KX_GameObject.cpp
source/gameengine/Ketsji/KX_IInterpolator.h
source/gameengine/Ketsji/KX_IPO_SGController.h
source/gameengine/Ketsji/KX_IPhysicsController.h
source/gameengine/Ketsji/KX_IScalarInterpolator.h
source/gameengine/Ketsji/KX_ISceneConverter.h
source/gameengine/Ketsji/KX_ISystem.h
source/gameengine/Ketsji/KX_KetsjiEngine.h
source/gameengine/Ketsji/KX_LightIpoSGController.h
source/gameengine/Ketsji/KX_MaterialIpoController.h
source/gameengine/Ketsji/KX_MotionState.h
source/gameengine/Ketsji/KX_ObColorIpoSGController.h
source/gameengine/Ketsji/KX_ObjectActuator.cpp
source/gameengine/Ketsji/KX_OrientationInterpolator.h
source/gameengine/Ketsji/KX_PolygonMaterial.cpp
source/gameengine/Ketsji/KX_PolygonMaterial.h
source/gameengine/Ketsji/KX_PositionInterpolator.h
source/gameengine/Ketsji/KX_PythonInit.cpp
source/gameengine/Ketsji/KX_RayCast.h
source/gameengine/Ketsji/KX_RayEventManager.h
source/gameengine/Ketsji/KX_SG_BoneParentNodeRelationship.h
source/gameengine/Ketsji/KX_SG_NodeRelationships.h
source/gameengine/Ketsji/KX_ScalarInterpolator.h
source/gameengine/Ketsji/KX_ScalingInterpolator.h
source/gameengine/Ketsji/KX_Scene.cpp
source/gameengine/Ketsji/KX_Scene.h
source/gameengine/Ketsji/KX_TimeCategoryLogger.h
source/gameengine/Ketsji/KX_TimeLogger.h
source/gameengine/Ketsji/KX_TouchEventManager.h
source/gameengine/Ketsji/KX_WorldInfo.h
source/gameengine/Ketsji/KX_WorldIpoController.h
source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.cpp
source/gameengine/Network/LoopBackNetwork/NG_LoopBackNetworkDeviceInterface.h
source/gameengine/Network/NG_NetworkDeviceInterface.h
source/gameengine/Network/NG_NetworkMessage.h
source/gameengine/Network/NG_NetworkObject.h
source/gameengine/Network/NG_NetworkScene.h
source/gameengine/Network/TerraplayNetwork/NG_TerraplayNetworkDeviceInterface.h
source/gameengine/Physics/Bullet/CcdGraphicController.h
source/gameengine/Physics/Bullet/CcdPhysicsController.h
source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.h
source/gameengine/Physics/Dummy/DummyPhysicsEnvironment.h
source/gameengine/Physics/common/PHY_IController.h
source/gameengine/Physics/common/PHY_IGraphicController.h
source/gameengine/Physics/common/PHY_IMotionState.h
source/gameengine/Physics/common/PHY_IPhysicsController.h
source/gameengine/Physics/common/PHY_IPhysicsEnvironment.h
source/gameengine/Physics/common/PHY_IVehicle.h
source/gameengine/PyDoc/bge.events.rst
source/gameengine/PyDoc/bge.logic.rst
source/gameengine/PyDoc/bge.render.rst
source/gameengine/PyDoc/bge.types.rst
source/gameengine/Rasterizer/Makefile
source/gameengine/Rasterizer/RAS_2DFilterManager.h
source/gameengine/Rasterizer/RAS_BucketManager.cpp
source/gameengine/Rasterizer/RAS_BucketManager.h
source/gameengine/Rasterizer/RAS_Deformer.h
source/gameengine/Rasterizer/RAS_FramingManager.h
source/gameengine/Rasterizer/RAS_ICanvas.h
source/gameengine/Rasterizer/RAS_IPolygonMaterial.h
source/gameengine/Rasterizer/RAS_IRasterizer.h
source/gameengine/Rasterizer/RAS_IRenderTools.h
source/gameengine/Rasterizer/RAS_MaterialBucket.h
source/gameengine/Rasterizer/RAS_MeshObject.h
source/gameengine/Rasterizer/RAS_OpenGLRasterizer/Makefile
source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_ListRasterizer.h
source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.h
source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_VAOpenGLRasterizer.h
source/gameengine/Rasterizer/RAS_Polygon.h
source/gameengine/Rasterizer/RAS_Rect.h
source/gameengine/Rasterizer/RAS_TexVert.h
source/gameengine/SceneGraph/SG_BBox.h
source/gameengine/SceneGraph/SG_Controller.h
source/gameengine/SceneGraph/SG_DList.h
source/gameengine/SceneGraph/SG_IObject.h
source/gameengine/SceneGraph/SG_Node.h
source/gameengine/SceneGraph/SG_ParentRelation.h
source/gameengine/SceneGraph/SG_QList.h
source/gameengine/SceneGraph/SG_Spatial.h
source/gameengine/SceneGraph/SG_Tree.h
source/gameengine/VideoTexture/ImageBase.cpp
source/gameengine/VideoTexture/VideoFFmpeg.cpp
source/gameengine/VideoTexture/blendVideoTex.cpp
source/nan_compile.mk

diff --git a/CMake/macros.cmake b/CMake/macros.cmake
deleted file mode 100644 (file)
index 54b14db..0000000
+++ /dev/null
@@ -1,178 +0,0 @@
-MACRO(BLENDERLIB_NOLIST
-  name
-  sources
-  includes)
-
-  # Gather all headers
-  FILE(GLOB_RECURSE INC_ALL *.h)
-     
-  INCLUDE_DIRECTORIES(${includes})
-  ADD_LIBRARY(${name} ${INC_ALL} ${sources})
-
-  # Group by location on disk
-  SOURCE_GROUP(Files FILES CMakeLists.txt)
-  SET(ALL_FILES ${sources} ${INC_ALL})
-  FOREACH(SRC ${ALL_FILES})
-    STRING(REGEX REPLACE ${CMAKE_CURRENT_SOURCE_DIR} "Files" REL_DIR "${SRC}")
-    STRING(REGEX REPLACE "[\\\\/][^\\\\/]*$" "" REL_DIR "${REL_DIR}")
-    STRING(REGEX REPLACE "^[\\\\/]" "" REL_DIR "${REL_DIR}")
-    IF(REL_DIR)
-      SOURCE_GROUP(${REL_DIR} FILES ${SRC})
-    ELSE(REL_DIR)
-      SOURCE_GROUP(Files FILES ${SRC})
-    ENDIF(REL_DIR)
-  ENDFOREACH(SRC)
-
-  MESSAGE(STATUS "Configuring library ${name}")
-ENDMACRO(BLENDERLIB_NOLIST)
-
-MACRO(BLENDERLIB
-  name
-  sources
-  includes)
-
-  BLENDERLIB_NOLIST(${name} "${sources}" "${includes}")
-
-  # Add to blender's list of libraries
-  FILE(APPEND ${CMAKE_BINARY_DIR}/cmake_blender_libs.txt "${name};")
-ENDMACRO(BLENDERLIB)
-
-MACRO(SETUP_LIBDIRS)
-  # see "cmake --help-policy CMP0003"
-  if(COMMAND cmake_policy)
-    CMAKE_POLICY(SET CMP0003 NEW)
-  endif(COMMAND cmake_policy)
-  
-  LINK_DIRECTORIES(${JPEG_LIBPATH} ${PNG_LIBPATH} ${ZLIB_LIBPATH} ${FREETYPE_LIBPATH} ${LIBSAMPLERATE_LIBPATH})
-  
-  IF(WITH_PYTHON)
-    LINK_DIRECTORIES(${PYTHON_LIBPATH})
-  ENDIF(WITH_PYTHON)
-  IF(WITH_INTERNATIONAL)
-    LINK_DIRECTORIES(${ICONV_LIBPATH})
-    LINK_DIRECTORIES(${GETTEXT_LIBPATH})
-  ENDIF(WITH_INTERNATIONAL)
-  IF(WITH_SDL)
-    LINK_DIRECTORIES(${SDL_LIBPATH})
-  ENDIF(WITH_SDL)
-  IF(WITH_FFMPEG)
-    LINK_DIRECTORIES(${FFMPEG_LIBPATH})
-  ENDIF(WITH_FFMPEG)
-  IF(WITH_OPENEXR)
-    LINK_DIRECTORIES(${OPENEXR_LIBPATH})
-  ENDIF(WITH_OPENEXR)
-  IF(WITH_TIFF)
-    LINK_DIRECTORIES(${TIFF_LIBPATH})
-  ENDIF(WITH_TIFF)
-  IF(WITH_QUICKTIME)
-    LINK_DIRECTORIES(${QUICKTIME_LIBPATH})
-  ENDIF(WITH_QUICKTIME)
-  IF(WITH_OPENAL)
-    LINK_DIRECTORIES(${OPENAL_LIBPATH})
-  ENDIF(WITH_OPENAL)
-  IF(WITH_JACK)
-    LINK_DIRECTORIES(${JACK_LIBPATH})
-  ENDIF(WITH_JACK)
-  IF(WITH_SNDFILE)
-    LINK_DIRECTORIES(${SNDFILE_LIBPATH})
-  ENDIF(WITH_SNDFILE)
-  IF(WITH_FFTW3)
-    LINK_DIRECTORIES(${FFTW3_LIBPATH})
-  ENDIF(WITH_FFTW3)
-  IF(WITH_OPENCOLLADA)
-    LINK_DIRECTORIES(${OPENCOLLADA_LIBPATH})
-    LINK_DIRECTORIES(${PCRE_LIBPATH})
-    LINK_DIRECTORIES(${EXPAT_LIBPATH})
-  ENDIF(WITH_OPENCOLLADA)
-
-  IF(WIN32)
-    LINK_DIRECTORIES(${PTHREADS_LIBPATH})
-  ENDIF(WIN32)
-ENDMACRO(SETUP_LIBDIRS)
-
-MACRO(SETUP_LIBLINKS
-  target)
-  SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${PLATFORM_LINKFLAGS} ")
-
-  TARGET_LINK_LIBRARIES(${target} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} ${JPEG_LIBRARY} ${PNG_LIBRARIES} ${ZLIB_LIBRARIES} ${LLIBS})
-
-  # since we are using the local libs for python when compiling msvc projects, we need to add _d when compiling debug versions
-  IF(WITH_PYTHON)
-    TARGET_LINK_LIBRARIES(${target} ${PYTHON_LINKFLAGS})
-  
-    IF(WIN32)
-      TARGET_LINK_LIBRARIES(${target} debug ${PYTHON_LIB}_d)
-      TARGET_LINK_LIBRARIES(${target} optimized ${PYTHON_LIB})
-    ELSE(WIN32)
-      TARGET_LINK_LIBRARIES(${target} ${PYTHON_LIB})
-    ENDIF(WIN32)
-  ENDIF(WITH_PYTHON)
-  
-  TARGET_LINK_LIBRARIES(${target} ${OPENGL_glu_LIBRARY} ${JPEG_LIB} ${PNG_LIB} ${ZLIB_LIB})
-  TARGET_LINK_LIBRARIES(${target} ${FREETYPE_LIBRARY} ${LIBSAMPLERATE_LIB})
-
-  IF(WITH_INTERNATIONAL)
-    TARGET_LINK_LIBRARIES(${target} ${GETTEXT_LIB})
-       
-    IF(WIN32)
-      TARGET_LINK_LIBRARIES(${target} ${ICONV_LIB})
-    ENDIF(WIN32)
-  ENDIF(WITH_INTERNATIONAL)
-  
-  IF(WITH_OPENAL)
-    TARGET_LINK_LIBRARIES(${target} ${OPENAL_LIBRARY})
-  ENDIF(WITH_OPENAL)
-  IF(WITH_FFTW3)  
-    TARGET_LINK_LIBRARIES(${target} ${FFTW3_LIB})
-  ENDIF(WITH_FFTW3)
-  IF(WITH_JACK)
-    TARGET_LINK_LIBRARIES(${target} ${JACK_LIB})
-  ENDIF(WITH_JACK)
-  IF(WITH_SNDFILE)
-    TARGET_LINK_LIBRARIES(${target} ${SNDFILE_LIB})
-  ENDIF(WITH_SNDFILE)
-  IF(WITH_SDL)
-    TARGET_LINK_LIBRARIES(${target} ${SDL_LIBRARY})
-  ENDIF(WITH_SDL)
-  IF(WITH_QUICKTIME)
-    TARGET_LINK_LIBRARIES(${target} ${QUICKTIME_LIB})
-  ENDIF(WITH_QUICKTIME)
-  IF(WITH_TIFF)
-    TARGET_LINK_LIBRARIES(${target} ${TIFF_LIBRARY})
-  ENDIF(WITH_TIFF)
-  IF(WITH_OPENEXR)
-    IF(WIN32)
-      FOREACH(loop_var ${OPENEXR_LIB})
-        TARGET_LINK_LIBRARIES(${target} debug ${loop_var}_d)
-        TARGET_LINK_LIBRARIES(${target} optimized ${loop_var})
-      ENDFOREACH(loop_var)
-    ELSE(WIN32)
-      TARGET_LINK_LIBRARIES(${target} ${OPENEXR_LIB})
-    ENDIF(WIN32)
-  ENDIF(WITH_OPENEXR)
-  IF(WITH_FFMPEG)
-    TARGET_LINK_LIBRARIES(${target} ${FFMPEG_LIB})
-  ENDIF(WITH_FFMPEG)
-  IF(WITH_OPENCOLLADA)
-    IF(WIN32)
-      FOREACH(loop_var ${OPENCOLLADA_LIB})
-        TARGET_LINK_LIBRARIES(${target} debug ${loop_var}_d)
-        TARGET_LINK_LIBRARIES(${target} optimized ${loop_var})
-      ENDFOREACH(loop_var)
-      TARGET_LINK_LIBRARIES(${target} debug ${PCRE_LIB}_d)
-      TARGET_LINK_LIBRARIES(${target} optimized ${PCRE_LIB})
-      IF(EXPAT_LIB)
-        TARGET_LINK_LIBRARIES(${target} debug ${EXPAT_LIB}_d)
-        TARGET_LINK_LIBRARIES(${target} optimized ${EXPAT_LIB})
-      ENDIF(EXPAT_LIB)
-    ELSE(WIN32)
-         TARGET_LINK_LIBRARIES(${target} ${OPENCOLLADA_LIB})
-      TARGET_LINK_LIBRARIES(${target} ${PCRE_LIB})
-      TARGET_LINK_LIBRARIES(${target} ${EXPAT_LIB})
-    ENDIF(WIN32)
-  ENDIF(WITH_OPENCOLLADA)
-  IF(WIN32)
-    TARGET_LINK_LIBRARIES(${target} ${PTHREADS_LIB})
-  ENDIF(WIN32)
-ENDMACRO(SETUP_LIBLINKS)
-
index 287b339..9c14bdd 100644 (file)
@@ -43,6 +43,10 @@ Remove the CMakeCache.txt file and try again from another folder, e.g.:
 ENDIF(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR})
 
 CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
+
+# quiet output for Makefiles, 'make -s' helps too
+# SET_PROPERTY(GLOBAL PROPERTY RULE_MESSAGES OFF)
+
 PROJECT(Blender)
 
 #-----------------------------------------------------------------------------
@@ -55,56 +59,84 @@ SET(LIBRARY_OUTPUT_PATH  ${CMAKE_BINARY_DIR}/lib)
 # ...but thats quite involved, make sure this matches the blender version.
 SET(BLENDER_VERSION  2.5)
 
+#-----------------------------------------------------------------------------
+# Load some macros.
+INCLUDE(build_files/cmake/macros.cmake)
+
 #-----------------------------------------------------------------------------
 # Set default config options
-OPTION(WITH_PLAYER        "Build Player" OFF)
-OPTION(WITH_GAMEENGINE    "Enable Game Engine" ON)
-OPTION(WITH_BULLET        "Enable Bullet (Physics Engine)" ON)
+
+# Blender internal features
 OPTION(WITH_INTERNATIONAL "Enable I18N   (International fonts and text)" ON)
+OPTION(WITH_LCMS          "Enable color correction with lcms" OFF)
+OPTION(WITH_PYTHON        "Enable Embedded Python API" ON)
+OPTION(WITH_BUILDINFO     "Include extra build details" ON)
 OPTION(WITH_ELBEEM        "Enable Elbeem (Fluid Simulation)" ON)
+OPTION(WITH_FFTW3         "Enable FFTW3 support (Used for smoke and audio effects)" OFF)
+OPTION(WITH_BULLET        "Enable Bullet (Physics Engine)" ON)
+OPTION(WITH_GAMEENGINE    "Enable Game Engine" ON)
+OPTION(WITH_PLAYER        "Build Player" OFF)
+# (unix defaults to OpenMP On)
+IF(UNIX AND NOT APPLE)
+       OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" ON)
+ELSE()
+       OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" OFF)
+ENDIF()
+
+# Image format support
 OPTION(WITH_OPENEXR       "Enable OpenEXR Support (http://www.openexr.com)" ON)
+OPTION(WITH_OPENJPEG      "Enable OpenJpeg Support (http://www.openjpeg.org/)" OFF)
 OPTION(WITH_TIFF          "Enable LibTIFF Support" ON)
 OPTION(WITH_DDS           "Enable DDS Support" ON)
+
+# Audio format support
 OPTION(WITH_FFMPEG        "Enable FFMPeg Support (http://ffmpeg.mplayerhq.hu/)" OFF)
-OPTION(WITH_PYTHON        "Enable Embedded Python API" ON)
-OPTION(WITH_SDL           "Enable SDL for sound and joystick support" ON)
-OPTION(WITH_OPENJPEG      "Enable OpenJpeg Support (http://www.openjpeg.org/)" OFF)
-OPTION(WITH_OPENAL        "Enable OpenAL Support (http://www.openal.org)" ON)
-OPTION(WITH_WEBPLUGIN     "Enable Web Plugin (Unix only)" OFF)
-OPTION(WITH_FFTW3         "Enable FFTW3 support" OFF)
-OPTION(WITH_JACK          "Enable Jack Support (http://www.jackaudio.org)" OFF)
 OPTION(WITH_SNDFILE       "Enable libsndfile Support (http://www.mega-nerd.com/libsndfile)" OFF)
-OPTION(WITH_LZO           "Enable fast LZO compression, used for pointcache" ON)
-OPTION(WITH_LZMA          "Enable best LZMA compression, used for pointcache" ON)
-OPTION(WITH_CXX_GUARDEDALLOC "Enable GuardedAlloc for C++ memory allocation" OFF)
-OPTION(WITH_BUILDINFO     "Include extra build details" ON)
-OPTION(WITH_INSTALL       "Install accompanying scripts and language files needed to run blender" ON)
-OPTION(WITH_RAYOPTIMIZATION    "Enable use of SIMD (SSE) optimizations for the raytracer" OFF) 
-
 IF(APPLE OR WIN32)
        OPTION(WITH_QUICKTIME     "Enable Quicktime Support" OFF)
 ENDIF(APPLE OR WIN32)
 
-# Unix defaults to OpenMP On
-# Disable opencollada on non-apple unix because opencollada has no package for debian
+# 3D format support
+# disable opencollada on non-apple unix because opencollada has no package for debian
 IF(UNIX AND NOT APPLE)
-       OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" ON)
        OPTION(WITH_OPENCOLLADA         "Enable OpenCollada Support (http://www.opencollada.org/)"      OFF)
 ELSE()
-       OPTION(WITH_OPENMP        "Enable OpenMP (has to be supported by the compiler)" OFF)
        OPTION(WITH_OPENCOLLADA         "Enable OpenCollada Support (http://www.opencollada.org/)"      OFF)
 ENDIF()
 
-IF (APPLE)
+# Sound output
+OPTION(WITH_SDL           "Enable SDL for sound and joystick support" ON)
+OPTION(WITH_OPENAL        "Enable OpenAL Support (http://www.openal.org)" ON)
+OPTION(WITH_JACK          "Enable Jack Support (http://www.jackaudio.org)" OFF)
+
+# Compression
+OPTION(WITH_LZO           "Enable fast LZO compression (used for pointcache)" ON)
+OPTION(WITH_LZMA          "Enable best LZMA compression, (used for pointcache)" ON)
+
+# Misc
+OPTION(WITH_RAYOPTIMIZATION    "Enable use of SIMD (SSE) optimizations for the raytracer" ON) 
+OPTION(WITH_CXX_GUARDEDALLOC "Enable GuardedAlloc for C++ memory allocation tracking" OFF)
+OPTION(WITH_INSTALL       "Install accompanying scripts and language files needed to run blender" ON)
+
+IF(APPLE)
        OPTION(WITH_COCOA         "Use Cocoa framework instead of deprecated Carbon" ON)
        OPTION(USE_QTKIT          "Use QtKit instead of Carbon quicktime (needed for having partial quicktime for 64bit)" OFF)
        OPTION(WITH_LIBS10.5  "Use 10.5 libs (needed for 64bit builds)" OFF)
-ENDIF (APPLE)
+ENDIF(APPLE)
+
+IF(NOT WITH_BULLET AND WITH_GAMEENGINE)
+       MESSAGE("WARNING: WITH_GAMEENGINE needs WITH_BULLET")
+ENDIF(NOT WITH_BULLET AND WITH_GAMEENGINE)
 
 IF(NOT WITH_GAMEENGINE AND WITH_PLAYER)
        MESSAGE("WARNING: WITH_PLAYER needs WITH_GAMEENGINE")
 ENDIF(NOT WITH_GAMEENGINE AND WITH_PLAYER)
 
+TEST_SSE_SUPPORT()
+
+# disabled for now, not supported
+# OPTION(WITH_WEBPLUGIN     "Enable Web Plugin (Unix only)" OFF)
+
 # For alternate Python locations the commandline can be used to override detected/default cache settings, e.g:
 # On Unix: 
 #   cmake -D PYTHON_LIB=/usr/local/lib/python3.1/config/libpython3.1.so -D PYTHON_INC=/usr/local/include/python3.1 -G "Unix Makefiles" ../blender
@@ -113,16 +145,11 @@ ENDIF(NOT WITH_GAMEENGINE AND WITH_PLAYER)
 #
 # When changing any of this remember to update the notes in doc/blender-cmake.txt
 
-#-----------------------------------------------------------------------------
-# Load some macros.
-INCLUDE(CMake/macros.cmake)
-
 #-----------------------------------------------------------------------------
 #Platform specifics
 
 IF(UNIX AND NOT APPLE)
 
-
        IF(WITH_OPENAL)
                FIND_PACKAGE(OpenAL)
                IF(NOT OPENAL_FOUND)
@@ -144,20 +171,23 @@ IF(UNIX AND NOT APPLE)
        SET(SNDFILE_LIBPATH ${SNDFILE}/lib)
        ENDIF(WITH_SNDFILE)
 
-       FIND_LIBRARY(INTL_LIBRARY
-               NAMES intl
-               PATHS
-               /sw/lib
-       )
-       FIND_LIBRARY(ICONV_LIBRARY
-               NAMES iconv
-               PATHS
-               /sw/lib
-       )
-  
-       IF(INTL_LIBRARY AND ICONV_LIBRARY)
-               SET(GETTEXT_LIB ${INTL_LIBRARY} ${ICONV_LIBRARY})
-       ENDIF(INTL_LIBRARY AND ICONV_LIBRARY)
+       IF(WITH_INTERNATIONAL)
+               FIND_LIBRARY(INTL_LIBRARY
+                       NAMES intl
+                       PATHS
+                       /sw/lib
+               )
+
+               FIND_LIBRARY(ICONV_LIBRARY
+                       NAMES iconv
+                       PATHS
+                       /sw/lib
+               )
+
+               IF(INTL_LIBRARY AND ICONV_LIBRARY)
+                       SET(GETTEXT_LIB ${INTL_LIBRARY} ${ICONV_LIBRARY})
+               ENDIF(INTL_LIBRARY AND ICONV_LIBRARY)
+       ENDIF(WITH_INTERNATIONAL)
 
        FIND_PACKAGE(Freetype)
        # UNSET(FREETYPE_INCLUDE_DIRS CACHE) # cant use
@@ -179,7 +209,6 @@ IF(UNIX AND NOT APPLE)
                SET(PYTHON_LINKFLAGS "-Xlinker -export-dynamic")
        ENDIF(WITH_PYTHON)
 
-
        IF(WITH_SDL)
                FIND_PACKAGE(SDL)
                # UNSET(SDLMAIN_LIBRARY CACHE)
@@ -201,15 +230,40 @@ IF(UNIX AND NOT APPLE)
                        /opt/include/OpenEXR
                )
                SET(OPENEXR_LIB Half IlmImf Iex Imath)
+               
+               IF(NOT OPENEXR_INC)
+                       SET(WITH_OPENEXR OFF)
+               ENDIF(NOT OPENEXR_INC)
        ENDIF(WITH_OPENEXR)
 
+       IF(WITH_TIFF)
+               FIND_PACKAGE(TIFF)
+               IF(NOT TIFF_FOUND)
+                       SET(WITH_TIFF OFF)
+               ENDIF(NOT TIFF_FOUND)
+       ENDIF(WITH_TIFF)
+
+       FIND_PACKAGE(JPEG REQUIRED)
+
+       FIND_PACKAGE(PNG REQUIRED)
+
+       FIND_PACKAGE(ZLIB REQUIRED)
+
+       IF(WITH_LCMS)
+               SET(LCMS /usr CACHE FILEPATH "LCMS directory")
+               SET(LCMS_INCLUDE_DIR ${LCMS}/include)
+               SET(LCMS_LIBRARY lcms)
+               SET(LCMS_LIBPATH ${LCMS}/lib)
+       ENDIF(WITH_LCMS)
+
        IF(WITH_FFMPEG)
                SET(FFMPEG /usr CACHE FILEPATH "FFMPEG Directory")
                SET(FFMPEG_INC ${FFMPEG}/include)
                SET(FFMPEG_LIB avformat avcodec avutil avdevice swscale CACHE STRING "FFMPEG Libraries")
                SET(FFMPEG_LIBPATH ${FFMPEG}/lib)
+               SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D__STDC_CONSTANT_MACROS")
        ENDIF(WITH_FFMPEG)
-  
+
        IF(WITH_FFTW3)
                SET(FFTW3 /usr)
                SET(FFTW3_INC ${FFTW3}/include)
@@ -222,19 +276,6 @@ IF(UNIX AND NOT APPLE)
        SET(LIBSAMPLERATE_LIB samplerate)
        SET(LIBSAMPLERATE_LIBPATH ${LIBSAMPLERATE}/lib)
 
-       IF(WITH_TIFF)
-               FIND_PACKAGE(TIFF)
-               IF(NOT TIFF_FOUND)
-                       SET(WITH_TIFF OFF)
-               ENDIF(NOT TIFF_FOUND)
-       ENDIF(WITH_TIFF)
-
-       FIND_PACKAGE(JPEG REQUIRED)
-
-       FIND_PACKAGE(PNG REQUIRED)
-
-       FIND_PACKAGE(ZLIB REQUIRED)
-
        IF (WITH_OPENCOLLADA)
                SET(OPENCOLLADA /usr/local/opencollada CACHE FILEPATH "OpenCollada Directory")
                SET(OPENCOLLADA_LIBPATH ${OPENCOLLADA}/lib)
@@ -270,6 +311,12 @@ IF(UNIX AND NOT APPLE)
 
        SET(PLATFORM_CFLAGS "-pipe -fPIC -funsigned-char -fno-strict-aliasing -Wno-char-subscripts")
 
+       IF(WITH_RAYOPTIMIZATION AND SUPPORT_SSE_BUILD)
+               SET(PLATFORM_CFLAGS " -msse -msse2 ${PLATFORM_CFLAGS}")
+               ADD_DEFINITIONS(-D__SSE__)
+               ADD_DEFINITIONS(-D__MMX__)
+       ENDIF(WITH_RAYOPTIMIZATION AND SUPPORT_SSE_BUILD)
+
        SET(PLATFORM_LINKFLAGS "-pthread")
 
        # Better warnings
@@ -295,10 +342,12 @@ IF(WIN32)
        
        ADD_DEFINITIONS(-DWIN32)
 
-       SET(ICONV ${LIBDIR}/iconv)
-       SET(ICONV_INC ${ICONV}/include)
-       SET(ICONV_LIB iconv)
-       SET(ICONV_LIBPATH ${ICONV}/lib)
+       IF(WITH_INTERNATIONAL)
+               SET(ICONV ${LIBDIR}/iconv)
+               SET(ICONV_INC ${ICONV}/include)
+               SET(ICONV_LIB iconv)
+               SET(ICONV_LIBPATH ${ICONV}/lib)
+       ENDIF(WITH_INTERNATIONAL)
 
        SET(LIBSAMPLERATE ${LIBDIR}/samplerate)
        SET(LIBSAMPLERATE_INC ${LIBSAMPLERATE}/include)
@@ -352,6 +401,11 @@ IF(WIN32)
                SET(QUICKTIME_LIBPATH ${QUICKTIME}/Libraries)
        ENDIF(WITH_QUICKTIME)
 
+       IF(WITH_RAYOPTIMIZATION AND SUPPORT_SSE_BUILD)
+               ADD_DEFINITIONS(-D__SSE__)
+               ADD_DEFINITIONS(-D__MMX__)
+       ENDIF(WITH_RAYOPTIMIZATION AND SUPPORT_SSE_BUILD)
+
        IF(MSVC)
                IF(CMAKE_CL_64)
                        SET(LLIBS kernel32 user32 vfw32 winmm ws2_32 )
@@ -376,14 +430,16 @@ IF(WIN32)
                        SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /openmp ")
                ENDIF(WITH_OPENMP)
                
-               SET(GETTEXT ${LIBDIR}/gettext)
-               SET(GETTEXT_INC ${GETTEXT}/include)
-               SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
-               IF(CMAKE_CL_64)
-                       SET(GETTEXT_LIB gettext)
-               ELSE(CMAKE_CL_64)
-                       SET(GETTEXT_LIB gnu_gettext)
-               ENDIF(CMAKE_CL_64)
+               IF(WITH_INTERNATIONAL)
+                       SET(GETTEXT ${LIBDIR}/gettext)
+                       SET(GETTEXT_INC ${GETTEXT}/include)
+                       SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
+                       IF(CMAKE_CL_64)
+                               SET(GETTEXT_LIB gettext)
+                       ELSE(CMAKE_CL_64)
+                               SET(GETTEXT_LIB gnu_gettext)
+                       ENDIF(CMAKE_CL_64)
+               ENDIF(WITH_INTERNATIONAL)
 
                IF(CMAKE_CL_64)
                        SET(PNG_LIBRARIES libpng)
@@ -422,13 +478,15 @@ IF(WIN32)
                        SET(OPENCOLLADA ${LIBDIR}/opencollada)
                        SET(OPENCOLLADA_INC ${OPENCOLLADA}/include)
                        SET(OPENCOLLADA_LIBPATH ${OPENCOLLADA}/lib)
-                       SET(OPENCOLLADA_LIB OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils OpenCOLLADAStreamWriter MathMLSolver GeneratedSaxParser UTF xml2 buffer ftoa)
+                       SET(OPENCOLLADA_LIB OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils OpenCOLLADAStreamWriter MathMLSolver GeneratedSaxParser xml2 buffer ftoa)
                        #pcre is bundled with openCollada
                        #SET(PCRE ${LIBDIR}/pcre)
                        #SET(PCRE_LIBPATH ${PCRE}/lib)
                        SET(PCRE_LIB pcre)
                ENDIF(WITH_OPENCOLLADA)
                
+               # TODO: IF(WITH_LCMS)
+        
                IF(WITH_FFMPEG)
                        SET(FFMPEG ${LIBDIR}/ffmpeg)
                        SET(FFMPEG_INC ${FFMPEG}/include ${FFMPEG}/include/msvc)
@@ -476,7 +534,7 @@ IF(WIN32)
        ELSE(MSVC) # MINGW
                SET(LLIBS "-lshell32 -lshfolder -lgdi32 -lmsvcrt -lwinmm -lmingw32 -lm -lws2_32 -lz -lstdc++ -lole32 -luuid")
 
-               SET(CMAKE_CXX_FLAGS                "-pipe -funsigned-char -fno-strict-aliasing -mwindows" CACHE STRING "Mingw C++ flags ")
+               SET(CMAKE_CXX_FLAGS                "-pipe -funsigned-char -fno-strict-aliasing" CACHE STRING "Mingw C++ flags ")
                SET(CMAKE_C_FLAGS                  "-pipe -funsigned-char -fno-strict-aliasing" CACHE STRING "Mingw C flags ")
 
                SET(CMAKE_CXX_FLAGS_DEBUG          "-O0 -g" CACHE STRING "Mingw debug C++ flags ")
@@ -496,12 +554,14 @@ IF(WIN32)
                        SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fopenmp")
                ENDIF(WITH_OPENMP)
 
-               SET(GETTEXT ${LIBDIR}/gcc/gettext)
-               SET(GETTEXT_INC ${GETTEXT}/include)
-               SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
-               SET(GETTEXT_LIB intl)
+               IF(WITH_INTERNATIONAL)
+                       SET(GETTEXT ${LIBDIR}/gcc/gettext)
+                       SET(GETTEXT_INC ${GETTEXT}/include)
+                       SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
+                       SET(GETTEXT_LIB intl)
+               ENDIF(WITH_INTERNATIONAL)
 
-               SET(JPEG_LIBRARY jpeg)
+               SET(JPEG_LIBRARY libjpeg)
                SET(PNG_LIBRARIES png)
 
                SET(ZLIB ${LIBDIR}/zlib)
@@ -547,7 +607,7 @@ IF(WIN32)
                IF(WITH_OPENEXR)
                        SET(OPENEXR ${LIBDIR}/gcc/openexr)
                        SET(OPENEXR_INC ${OPENEXR}/include ${OPENEXR}/include/OpenEXR)
-                       SET(OPENEXR_LIB Half IlmImf Iex)
+                       SET(OPENEXR_LIB Half IlmImf Imath IlmThread)
                        SET(OPENEXR_LIBPATH ${OPENEXR}/lib)
                ENDIF(WITH_OPENEXR)
 
@@ -632,10 +692,12 @@ IF(APPLE)
                SET(PYTHON_LINKFLAGS "-u _PyMac_Error -framework System -framework Python")
        ENDIF(PYTHON_VERSION MATCHES 3.1)
 
-       SET(GETTEXT ${LIBDIR}/gettext)
-       SET(GETTEXT_INC "${GETTEXT}/include")
-       SET(GETTEXT_LIB intl iconv)
-       SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
+       IF(WITH_INTERNATIONAL)
+               SET(GETTEXT ${LIBDIR}/gettext)
+               SET(GETTEXT_INC "${GETTEXT}/include")
+               SET(GETTEXT_LIB intl iconv)
+               SET(GETTEXT_LIBPATH ${GETTEXT}/lib)
+       ENDIF(WITH_INTERNATIONAL)
   
        IF(WITH_FFTW3)
                SET(FFTW3 ${LIBDIR}/fftw3)
@@ -656,15 +718,27 @@ IF(APPLE)
        SET(FREETYPE_LIBPATH ${FREETYPE}/lib)
        SET(FREETYPE_LIBRARY freetype)
 
-       SET(OPENEXR ${LIBDIR}/openexr)
-       SET(OPENEXR_INC ${OPENEXR}/include/OpenEXR ${OPENEXR}/include)
-       SET(OPENEXR_LIB Iex Half IlmImf Imath IlmThread)
-       SET(OPENEXR_LIBPATH ${OPENEXR}/lib)
+       IF(WITH_OPENEXR)
+               SET(OPENEXR ${LIBDIR}/openexr)
+               SET(OPENEXR_INC ${OPENEXR}/include/OpenEXR ${OPENEXR}/include)
+               SET(OPENEXR_LIB Iex Half IlmImf Imath IlmThread)
+               SET(OPENEXR_LIBPATH ${OPENEXR}/lib)
+       ENDIF(WITH_OPENEXR)
+
+       IF(WITH_LCMS)
+               SET(LCMS ${LIBDIR}/lcms)
+               SET(LCMS_INCLUDE_DIR ${LCMS}/include)
+               SET(LCMS_LIBRARY lcms)
+               SET(LCMS_LIBPATH ${LCMS}/lib)
+       ENDIF(WITH_LCMS)
 
-       SET(FFMPEG ${LIBDIR}/ffmpeg)
-       SET(FFMPEG_INC ${FFMPEG}/include)
-       SET(FFMPEG_LIB avcodec avdevice avformat avutil mp3lame swscale x264 xvidcore theora theoradec theoraenc vorbis vorbisenc vorbisfile ogg)
-       SET(FFMPEG_LIBPATH ${FFMPEG}/lib)
+       IF(WITH_FFMPEG)
+               SET(FFMPEG ${LIBDIR}/ffmpeg)
+               SET(FFMPEG_INC ${FFMPEG}/include)
+               SET(FFMPEG_LIB avcodec avdevice avformat avutil mp3lame swscale x264 xvidcore theora theoradec theoraenc vorbis vorbisenc vorbisfile ogg)
+               SET(FFMPEG_LIBPATH ${FFMPEG}/lib)
+               SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D__STDC_CONSTANT_MACROS")
+       ENDIF(WITH_FFMPEG)
 
        SET(LIBSAMPLERATE ${LIBDIR}/samplerate)
        SET(LIBSAMPLERATE_INC ${LIBSAMPLERATE}/include)
@@ -712,10 +786,12 @@ IF(APPLE)
                SET(EXPAT_LIB)
        ENDIF (WITH_OPENCOLLADA)
 
-       SET(SDL ${LIBDIR}/sdl)
-       SET(SDL_INCLUDE_DIR ${SDL}/include)
-       SET(SDL_LIBRARY SDL)
-       SET(SDL_LIBPATH ${SDL}/lib)
+       IF(WITH_SDL)
+               SET(SDL ${LIBDIR}/sdl)
+               SET(SDL_INCLUDE_DIR ${SDL}/include)
+               SET(SDL_LIBRARY SDL)
+               SET(SDL_LIBPATH ${SDL}/lib)
+       ENDIF(WITH_SDL)
 
        SET(PNG "${LIBDIR}/png")
        SET(PNG_INC "${PNG}/include")
@@ -725,10 +801,18 @@ IF(APPLE)
        SET(JPEG_INC "${JPEG}/include")
        SET(JPEG_LIBPATH ${JPEG}/lib)
 
-       SET(TIFF ${LIBDIR}/tiff)
-       SET(TIFF_INCLUDE_DIR ${TIFF}/include)
-       SET(TIFF_LIBRARY tiff)
-       SET(TIFF_LIBPATH ${TIFF}/lib)
+       IF(WITH_TIFF)
+               SET(TIFF ${LIBDIR}/tiff)
+               SET(TIFF_INCLUDE_DIR ${TIFF}/include)
+               SET(TIFF_LIBRARY tiff)
+               SET(TIFF_LIBPATH ${TIFF}/lib)
+       ENDIF(WITH_TIFF)
+
+       IF(WITH_RAYOPTIMIZATION AND SUPPORT_SSE_BUILD)
+               SET(PLATFORM_CFLAGS " -msse -msse2 ${PLATFORM_CFLAGS}")
+               ADD_DEFINITIONS(-D__SSE__)
+               ADD_DEFINITIONS(-D__MMX__)
+       ENDIF(WITH_RAYOPTIMIZATION AND SUPPORT_SSE_BUILD)
 
        SET(EXETYPE MACOSX_BUNDLE)
 
@@ -776,10 +860,11 @@ ENDIF(WITH_BUILDINFO)
        
 #-----------------------------------------------------------------------------
 # Common.
-
-set(OPENJPEG ${CMAKE_SOURCE_DIR}/extern/libopenjpeg)
-set(OPENJPEG_INC ${OPENJPEG})
-set(OPENJPEG_LIb extern_libopenjpeg)
+IF(WITH_OPENJPEG)
+       set(OPENJPEG ${CMAKE_SOURCE_DIR}/extern/libopenjpeg)
+       set(OPENJPEG_INC ${OPENJPEG})
+       set(OPENJPEG_LIb extern_libopenjpeg)
+ENDIF(WITH_OPENJPEG)
 
 #-----------------------------------------------------------------------------
 # Blender WebPlugin
index dc6198b..09ada7d 100644 (file)
@@ -46,6 +46,9 @@ import glob
 import re
 from tempfile import mkdtemp
 
+# needed for importing tools
+sys.path.append(os.path.join(".", "build_files", "scons"))
+
 import tools.Blender
 import tools.btools
 import tools.bcolors
@@ -56,6 +59,8 @@ BlenderEnvironment = tools.Blender.BlenderEnvironment
 btools = tools.btools
 B = tools.Blender
 
+VERSION = tools.btools.VERSION # This is used in creating the local config directories
+
 ### globals ###
 platform = sys.platform
 quickie = None
@@ -157,7 +162,7 @@ if crossbuild and platform not in ('win32-vc', 'win64-vc'):
 
 env['OURPLATFORM'] = platform
 
-configfile = 'config'+os.sep+platform+'-config.py'
+configfile = os.path.join("build_files", "scons", "config", platform + "-config.py")
 
 if os.path.exists(configfile):
        print B.bc.OKGREEN + "Using config file: " + B.bc.ENDC + configfile
@@ -193,7 +198,7 @@ if not env['BF_FANCY']:
 # NOTE: only do the scripts directory for now, otherwise is too disruptive for developers
 # TODO: perhaps we need an option (off by default) to not do this altogether...
 if not env['WITHOUT_BF_INSTALL'] and not env['WITHOUT_BF_OVERWRITE_INSTALL']:
-       scriptsDir = env['BF_INSTALLDIR'] + os.sep + '.blender' + os.sep + 'scripts'
+       scriptsDir = os.path.join(env['BF_INSTALLDIR'], VERSION, 'scripts')
        if os.path.isdir(scriptsDir):
                print B.bc.OKGREEN + "Clearing installation directory%s: %s" % (B.bc.ENDC, os.path.abspath(scriptsDir))
                shutil.rmtree(scriptsDir)
@@ -201,6 +206,7 @@ if not env['WITHOUT_BF_INSTALL'] and not env['WITHOUT_BF_OVERWRITE_INSTALL']:
 
 SetOption('num_jobs', int(env['BF_NUMJOBS']))
 print B.bc.OKGREEN + "Build with parallel jobs%s: %s" % (B.bc.ENDC, GetOption('num_jobs'))
+print B.bc.OKGREEN + "Build with debug symbols%s: %s" % (B.bc.ENDC, env['BF_DEBUG'])
 
 # BLENDERPATH is a unix only option to enable typical style paths this is
 # spesifically a data-dir, which is used a lot but cant replace BF_INSTALLDIR
@@ -268,6 +274,7 @@ if 'blenderlite' in B.targets:
        target_env_defs['WITH_BF_GAMEENGINE'] = False
        target_env_defs['WITH_BF_OPENAL'] = False
        target_env_defs['WITH_BF_OPENEXR'] = False
+       target_env_defs['WITH_BF_OPENMP'] = False
        target_env_defs['WITH_BF_ICONV'] = False
        target_env_defs['WITH_BF_INTERNATIONAL'] = False
        target_env_defs['WITH_BF_OPENJPEG'] = False
@@ -432,9 +439,11 @@ else:
        
        blenderinstall = env.Install(dir=dir, source=B.program_list)
 
-#-- .blender
-#- dont do .blender and scripts for darwin, it is already in the bundle
+#-- local path = config files in install dir: installdir\VERSION
+#- dont do config and scripts for darwin, it is already in the bundle
 dotblendlist = []
+datafileslist = []
+datafilestargetlist = []
 dottargetlist = []
 scriptinstall = []
 
@@ -453,20 +462,29 @@ if  env['OURPLATFORM']!='darwin':
                                        if f.endswith('.ttf'):
                                                continue
                                
-                               dotblendlist.append(os.path.join(dp, f))
-                               if env['WITH_BF_FHS']:  dir= os.path.join(*([BLENDERPATH] + dp.split(os.sep)[2:]))      # skip bin/.blender
-                               else:                                   dir= os.path.join(*([BLENDERPATH] + dp.split(os.sep)[1:]))      # skip bin
-                               
-                               dottargetlist.append(dir + os.sep + f)
-                                       
+                               if 'locale' in dp:
+                                       datafileslist.append(os.path.join(dp,f))
+                                       if env['WITH_BF_FHS']:  dir= os.path.join(*([BLENDERPATH] + ['datafiles'] + dp.split(os.sep)[2:]))      # skip bin/.blender
+                                       else:                                   dir= os.path.join(*([BLENDERPATH] + [VERSION] + ['datafiles'] + dp.split(os.sep)[1:]))  # skip bin
+                                       datafilestargetlist.append(dir + os.sep + f)
 
+                               else:
+                                       dotblendlist.append(os.path.join(dp, f))
+                                       if env['WITH_BF_FHS']:  dir= os.path.join(*([BLENDERPATH] + ['config'] + dp.split(os.sep)[2:])) # skip bin/.blender
+                                       else:                                   dir= os.path.join(*([BLENDERPATH] + [VERSION] + ['config'] + dp.split(os.sep)[1:]))     # skip bin
+                                       
+                                       dottargetlist.append(dir + os.sep + f)
+                                       
                dotblenderinstall = []
                for targetdir,srcfile in zip(dottargetlist, dotblendlist):
                        td, tf = os.path.split(targetdir)
                        dotblenderinstall.append(env.Install(dir=td, source=srcfile))
+               for targetdir,srcfile in zip(datafilestargetlist, datafileslist):
+                       td, tf = os.path.split(targetdir)
+                       dotblenderinstall.append(env.Install(dir=td, source=srcfile))
                
                if env['WITH_BF_PYTHON']:
-                       #-- .blender/scripts
+                       #-- local/VERSION/scripts
                        scriptpaths=['release/scripts']
                        for scriptpath in scriptpaths:
                                for dp, dn, df in os.walk(scriptpath):
@@ -474,7 +492,7 @@ if  env['OURPLATFORM']!='darwin':
                                                dn.remove('.svn')
                                        
                                        if env['WITH_BF_FHS']:          dir = BLENDERPATH
-                                       else:                                           dir = os.path.join(env['BF_INSTALLDIR'], '.blender')                            
+                                       else:                                           dir = os.path.join(env['BF_INSTALLDIR'], VERSION)                               
                                        dir += os.sep + os.path.basename(scriptpath) + dp[len(scriptpath):]
                                        
                                        source=[os.path.join(dp, f) for f in df if f[-3:]!='pyc']
diff --git a/build_files/cmake/macros.cmake b/build_files/cmake/macros.cmake
new file mode 100644 (file)
index 0000000..aec86f7
--- /dev/null
@@ -0,0 +1,200 @@
+MACRO(BLENDERLIB_NOLIST
+       name
+       sources
+       includes)
+
+       # Gather all headers
+       FILE(GLOB_RECURSE INC_ALL *.h)
+                
+       INCLUDE_DIRECTORIES(${includes})
+       ADD_LIBRARY(${name} ${INC_ALL} ${sources})
+
+       # Group by location on disk
+       SOURCE_GROUP(Files FILES CMakeLists.txt)
+       SET(ALL_FILES ${sources} ${INC_ALL})
+       FOREACH(SRC ${ALL_FILES})
+               STRING(REGEX REPLACE ${CMAKE_CURRENT_SOURCE_DIR} "Files" REL_DIR "${SRC}")
+               STRING(REGEX REPLACE "[\\\\/][^\\\\/]*$" "" REL_DIR "${REL_DIR}")
+               STRING(REGEX REPLACE "^[\\\\/]" "" REL_DIR "${REL_DIR}")
+               IF(REL_DIR)
+                       SOURCE_GROUP(${REL_DIR} FILES ${SRC})
+               ELSE(REL_DIR)
+                       SOURCE_GROUP(Files FILES ${SRC})
+               ENDIF(REL_DIR)
+       ENDFOREACH(SRC)
+
+       MESSAGE(STATUS "Configuring library ${name}")
+ENDMACRO(BLENDERLIB_NOLIST)
+
+MACRO(BLENDERLIB
+       name
+       sources
+       includes)
+
+       BLENDERLIB_NOLIST(${name} "${sources}" "${includes}")
+
+       # Add to blender's list of libraries
+       FILE(APPEND ${CMAKE_BINARY_DIR}/cmake_blender_libs.txt "${name};")
+ENDMACRO(BLENDERLIB)
+
+MACRO(SETUP_LIBDIRS)
+       # see "cmake --help-policy CMP0003"
+       if(COMMAND cmake_policy)
+               CMAKE_POLICY(SET CMP0003 NEW)
+       endif(COMMAND cmake_policy)
+       
+       LINK_DIRECTORIES(${JPEG_LIBPATH} ${PNG_LIBPATH} ${ZLIB_LIBPATH} ${FREETYPE_LIBPATH} ${LIBSAMPLERATE_LIBPATH})
+       
+       IF(WITH_PYTHON)
+               LINK_DIRECTORIES(${PYTHON_LIBPATH})
+       ENDIF(WITH_PYTHON)
+       IF(WITH_INTERNATIONAL)
+               LINK_DIRECTORIES(${ICONV_LIBPATH})
+               LINK_DIRECTORIES(${GETTEXT_LIBPATH})
+       ENDIF(WITH_INTERNATIONAL)
+       IF(WITH_SDL)
+               LINK_DIRECTORIES(${SDL_LIBPATH})
+       ENDIF(WITH_SDL)
+       IF(WITH_FFMPEG)
+               LINK_DIRECTORIES(${FFMPEG_LIBPATH})
+       ENDIF(WITH_FFMPEG)
+       IF(WITH_OPENEXR)
+               LINK_DIRECTORIES(${OPENEXR_LIBPATH})
+       ENDIF(WITH_OPENEXR)
+       IF(WITH_TIFF)
+               LINK_DIRECTORIES(${TIFF_LIBPATH})
+       ENDIF(WITH_TIFF)
+       IF(WITH_LCMS)
+               LINK_DIRECTORIES(${LCMS_LIBPATH})
+       ENDIF(WITH_LCMS)
+       IF(WITH_QUICKTIME)
+               LINK_DIRECTORIES(${QUICKTIME_LIBPATH})
+       ENDIF(WITH_QUICKTIME)
+       IF(WITH_OPENAL)
+               LINK_DIRECTORIES(${OPENAL_LIBPATH})
+       ENDIF(WITH_OPENAL)
+       IF(WITH_JACK)
+               LINK_DIRECTORIES(${JACK_LIBPATH})
+       ENDIF(WITH_JACK)
+       IF(WITH_SNDFILE)
+               LINK_DIRECTORIES(${SNDFILE_LIBPATH})
+       ENDIF(WITH_SNDFILE)
+       IF(WITH_FFTW3)
+               LINK_DIRECTORIES(${FFTW3_LIBPATH})
+       ENDIF(WITH_FFTW3)
+       IF(WITH_OPENCOLLADA)
+               LINK_DIRECTORIES(${OPENCOLLADA_LIBPATH})
+               LINK_DIRECTORIES(${PCRE_LIBPATH})
+               LINK_DIRECTORIES(${EXPAT_LIBPATH})
+       ENDIF(WITH_OPENCOLLADA)
+
+       IF(WIN32)
+               LINK_DIRECTORIES(${PTHREADS_LIBPATH})
+       ENDIF(WIN32)
+ENDMACRO(SETUP_LIBDIRS)
+
+MACRO(SETUP_LIBLINKS
+       target)
+       SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${PLATFORM_LINKFLAGS} ")
+
+       TARGET_LINK_LIBRARIES(${target} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} ${JPEG_LIBRARY} ${PNG_LIBRARIES} ${ZLIB_LIBRARIES} ${LLIBS})
+
+       # since we are using the local libs for python when compiling msvc projects, we need to add _d when compiling debug versions
+       IF(WITH_PYTHON)
+               TARGET_LINK_LIBRARIES(${target} ${PYTHON_LINKFLAGS})
+
+               IF(WIN32)
+                       TARGET_LINK_LIBRARIES(${target} debug ${PYTHON_LIB}_d)
+                       TARGET_LINK_LIBRARIES(${target} optimized ${PYTHON_LIB})
+               ELSE(WIN32)
+                       TARGET_LINK_LIBRARIES(${target} ${PYTHON_LIB})
+               ENDIF(WIN32)
+       ENDIF(WITH_PYTHON)
+
+       TARGET_LINK_LIBRARIES(${target} ${OPENGL_glu_LIBRARY} ${JPEG_LIB} ${PNG_LIB} ${ZLIB_LIB})
+       TARGET_LINK_LIBRARIES(${target} ${FREETYPE_LIBRARY} ${LIBSAMPLERATE_LIB})
+
+       IF(WITH_INTERNATIONAL)
+               TARGET_LINK_LIBRARIES(${target} ${GETTEXT_LIB})
+
+               IF(WIN32)
+                       TARGET_LINK_LIBRARIES(${target} ${ICONV_LIB})
+               ENDIF(WIN32)
+       ENDIF(WITH_INTERNATIONAL)
+
+       IF(WITH_OPENAL)
+               TARGET_LINK_LIBRARIES(${target} ${OPENAL_LIBRARY})
+       ENDIF(WITH_OPENAL)
+       IF(WITH_FFTW3)  
+               TARGET_LINK_LIBRARIES(${target} ${FFTW3_LIB})
+       ENDIF(WITH_FFTW3)
+       IF(WITH_JACK)
+               TARGET_LINK_LIBRARIES(${target} ${JACK_LIB})
+       ENDIF(WITH_JACK)
+       IF(WITH_SNDFILE)
+               TARGET_LINK_LIBRARIES(${target} ${SNDFILE_LIB})
+       ENDIF(WITH_SNDFILE)
+       IF(WITH_SDL)
+               TARGET_LINK_LIBRARIES(${target} ${SDL_LIBRARY})
+       ENDIF(WITH_SDL)
+       IF(WITH_QUICKTIME)
+               TARGET_LINK_LIBRARIES(${target} ${QUICKTIME_LIB})
+       ENDIF(WITH_QUICKTIME)
+       IF(WITH_TIFF)
+               TARGET_LINK_LIBRARIES(${target} ${TIFF_LIBRARY})
+       ENDIF(WITH_TIFF)
+       IF(WITH_OPENEXR)
+               IF(WIN32)
+                       FOREACH(loop_var ${OPENEXR_LIB})
+                               TARGET_LINK_LIBRARIES(${target} debug ${loop_var}_d)
+                               TARGET_LINK_LIBRARIES(${target} optimized ${loop_var})
+                       ENDFOREACH(loop_var)
+               ELSE(WIN32)
+                       TARGET_LINK_LIBRARIES(${target} ${OPENEXR_LIB})
+               ENDIF(WIN32)
+       ENDIF(WITH_OPENEXR)
+       IF(WITH_LCMS)
+               TARGET_LINK_LIBRARIES(${target} ${LCMS_LIBRARY})
+       ENDIF(WITH_LCMS)
+       IF(WITH_FFMPEG)
+               TARGET_LINK_LIBRARIES(${target} ${FFMPEG_LIB})
+       ENDIF(WITH_FFMPEG)
+       IF(WITH_OPENCOLLADA)
+               IF(WIN32)
+                       FOREACH(loop_var ${OPENCOLLADA_LIB})
+                               TARGET_LINK_LIBRARIES(${target} debug ${loop_var}_d)
+                               TARGET_LINK_LIBRARIES(${target} optimized ${loop_var})
+                       ENDFOREACH(loop_var)
+                       TARGET_LINK_LIBRARIES(${target} debug ${PCRE_LIB}_d)
+                       TARGET_LINK_LIBRARIES(${target} optimized ${PCRE_LIB})
+                       IF(EXPAT_LIB)
+                               TARGET_LINK_LIBRARIES(${target} debug ${EXPAT_LIB}_d)
+                               TARGET_LINK_LIBRARIES(${target} optimized ${EXPAT_LIB})
+                       ENDIF(EXPAT_LIB)
+               ELSE(WIN32)
+               TARGET_LINK_LIBRARIES(${target} ${OPENCOLLADA_LIB})
+                       TARGET_LINK_LIBRARIES(${target} ${PCRE_LIB})
+                       TARGET_LINK_LIBRARIES(${target} ${EXPAT_LIB})
+               ENDIF(WIN32)
+       ENDIF(WITH_OPENCOLLADA)
+       IF(WIN32)
+               TARGET_LINK_LIBRARIES(${target} ${PTHREADS_LIB})
+       ENDIF(WIN32)
+ENDMACRO(SETUP_LIBLINKS)
+
+MACRO(TEST_SSE_SUPPORT)
+       INCLUDE(CheckCXXSourceCompiles)
+
+       MESSAGE(STATUS "Detecting SSE support")
+       IF(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
+               SET(CMAKE_REQUIRED_FLAGS "-msse -msse2")
+       ELSEIF(MSVC)
+               SET(CMAKE_REQUIRED_FLAGS "/arch:SSE2")
+       ENDIF()
+
+       CHECK_CXX_SOURCE_COMPILES("
+               #include <xmmintrin.h>
+               int main() { __m128 v = _mm_setzero_ps(); return 0; }"
+       SUPPORT_SSE_BUILD)
+ENDMACRO(TEST_SSE_SUPPORT)
+
diff --git a/build_files/make/example_scripts/linux_nanmakefiles.sh b/build_files/make/example_scripts/linux_nanmakefiles.sh
new file mode 100755 (executable)
index 0000000..aa8d882
--- /dev/null
@@ -0,0 +1,38 @@
+#!/bin/sh
+
+#
+# This is an example script to build things with the Nan Makefiles
+#
+#
+
+rm -f /tmp/.nanguess
+export MAKE=make
+export NANBLENDERHOME=`pwd`
+export MAKEFLAGS="-w -I $NANBLENDERHOME/source --no-print-directory"
+export HMAKE="$NANBLENDERHOME/source/tools/hmake/hmake"
+
+export NAN_PYTHON=/soft/python-2.2.2b1/progeny1
+export NAN_PYTHON_VERSION=2.2
+export NAN_OPENAL=/usr/local
+export NAN_JPEG=/usr/local
+export NAN_PNG=/usr/local
+export NAN_SDL=/usr/local
+export NAN_ODE=/usr/local
+export NAN_ZLIB=/usr/local
+export NAN_FREETYPE=/usr/local
+
+export NAN_MOZILLA_INC=/usr/local/include/mozilla-1.0.1/
+export NAN_MOZILLA_LIB=/usr/local/lib/mozilla-1.0.1/
+#export NAN_NSPR=/scratch/irulan/mein/nspr-4.2.2/mozilla/nsprpub/dist/
+export CPPFLAGS="$CPPFLAGS"
+export CFLAGS="$CFLAGS"
+export INTERNATIONAL=true
+
+$HMAKE -C intern/
+if [ $? -eq 0 ]; then
+        $HMAKE -C source/
+fi
+$HMAKE -C release
+
+#cd release
+#make
diff --git a/build_files/make/example_scripts/macos_nanmakefiles.sh b/build_files/make/example_scripts/macos_nanmakefiles.sh
new file mode 100755 (executable)
index 0000000..d2cce20
--- /dev/null
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+rm -f /tmp/.nanguess
+export MAKE=make
+export NANBLENDERHOME=`pwd`
+export MAKEFLAGS="-w -I $NANBLENDERHOME/source --no-print-directory"
+export HMAKE="$NANBLENDERHOME/source/tools/hmake/hmake"
+echo 
+echo NANBLENDERHOME : ${NANBLENDERHOME}
+
+export NAN_PYTHON=/sw
+
+$HMAKE -C intern/
+if [ $? -eq 0 ]; then
+        $HMAKE -C source/
+fi
+cd release
+make
diff --git a/build_files/make/example_scripts/sunos_nanmakefiles.sh b/build_files/make/example_scripts/sunos_nanmakefiles.sh
new file mode 100755 (executable)
index 0000000..25dd17b
--- /dev/null
@@ -0,0 +1,35 @@
+#!/bin/sh
+# This is an example build script for SunOS5.8
+
+rm -f /tmp/.nanguess
+export MAKE=make
+export NANBLENDERHOME=`pwd`
+export MAKEFLAGS="-w -I $NANBLENDERHOME/source --no-print-directory"
+export HMAKE="$NANBLENDERHOME/source/tools/hmake/hmake"
+
+export NAN_PYTHON=/soft/python-2.2.2b1/SunOS5.8
+export NAN_PYTHON_VERSION=2.2
+export NAN_OPENAL=/usr/local
+export NAN_JPEG=/usr/local
+export NAN_PNG=/usr/local
+export NAN_SDL=/usr/local
+export NAN_ODE=/usr/local
+export NAN_OPENSSL=/soft/ssl/openssl-0.9.6e
+export NAN_ZLIB=/usr/local
+export NAN_FREETYPE=/usr/local
+
+export NAN_MOZILLA_INC=/usr/local/include/mozilla-1.0.1/
+export NAN_MOZILLA_LIB=/usr/local/lib/mozilla-1.0.1/
+export NAN_NSPR=/scratch/irulan/mein/nspr-4.2.2/mozilla/nsprpub/dist/
+export CPPFLAGS="$CPPFLAGS"
+export CFLAGS="$CFLAGS"
+export INTERNATIONAL=true
+
+$HMAKE -C intern/
+if [ $? -eq 0 ]; then
+        $HMAKE -C source/
+fi
+$HMAKE -C release
+
+#cd release
+#make
similarity index 96%
rename from config/aix4-config.py
rename to build_files/scons/config/aix4-config.py
index 32344cd..a769f53 100644 (file)
@@ -83,22 +83,11 @@ BF_FTGL_LIB = 'extern_ftgl'
 
 WITH_BF_GAMEENGINE='false'
 
-WITH_BF_ODE = 'false'
-BF_ODE = LIBDIR + '/ode'
-BF_ODE_INC = BF_ODE + '/include'
-BF_ODE_LIB = BF_ODE + '/lib/libode.a'
-
 WITH_BF_BULLET = 'true'
 BF_BULLET = '#extern/bullet2/src'
 BF_BULLET_INC = '${BF_BULLET}'
 BF_BULLET_LIB = 'extern_bullet'
 
-BF_SOLID = '#extern/solid'
-BF_SOLID_INC = '${BF_SOLID}'
-BF_SOLID_LIB = 'extern_solid'
-
-WITH_BF_YAFRAY = 'true'
-
 #WITH_BF_NSPR = 'true'
 #BF_NSPR = $(LIBDIR)/nspr
 #BF_NSPR_INC = -I$(BF_NSPR)/include -I$(BF_NSPR)/include/nspr
similarity index 97%
rename from config/darwin-config.py
rename to build_files/scons/config/darwin-config.py
index 2c3d0a7..1423e8f 100644 (file)
@@ -151,6 +151,13 @@ BF_OPENEXR_LIB_STATIC = '${BF_OPENEXR}/lib/libHalf.a ${BF_OPENEXR}/lib/libIlmImf
 
 WITH_BF_DDS = True
 
+#Color Management System
+WITH_BF_LCMS = False
+BF_LCMS = LIBDIR + '/lcms'
+BF_LCMS_INC = '${BF_LCMS}/include'
+BF_LCMS_LIB = 'lcms'
+BF_LCMS_LIBPATH = '${BF_LCMS}/lib'
+
 WITH_BF_JPEG = True
 BF_JPEG = LIBDIR + '/jpeg'
 BF_JPEG_INC = '${BF_JPEG}/include'
@@ -272,9 +279,9 @@ else:
 
 CFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS
 
-CPPFLAGS = ['-fpascal-strings']+ARCH_FLAGS
-CCFLAGS = ['-pipe','-funsigned-char','-fpascal-strings']+ARCH_FLAGS
-CXXFLAGS = ['-pipe','-funsigned-char', '-fpascal-strings']+ARCH_FLAGS
+CPPFLAGS = []+ARCH_FLAGS
+CCFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS
+CXXFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS
 
 if WITH_GHOST_COCOA==True:
        PLATFORM_LINKFLAGS = ['-fexceptions','-framework','CoreServices','-framework','Foundation','-framework','IOKit','-framework','AppKit','-framework','Cocoa','-framework','Carbon','-framework','AudioUnit','-framework','AudioToolbox','-framework','CoreAudio','-framework','OpenAL']+ARCH_FLAGS
similarity index 98%
rename from config/linux2-config.py
rename to build_files/scons/config/linux2-config.py
index 199ea39..7a350a7 100644 (file)
@@ -168,7 +168,7 @@ BF_EXPAT_LIBPATH = '/usr/lib'
 WITH_BF_OPENMP = True
 
 #Ray trace optimization
-WITH_BF_RAYOPTIMIZATION = False
+WITH_BF_RAYOPTIMIZATION = True
 BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse','-pthread']
 
 ##
@@ -181,6 +181,9 @@ CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFIL
 
 CPPFLAGS = []
 CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
+if WITH_BF_FFMPEG:
+  # libavutil needs UINT64_C()
+  CXXFLAGS += ['-D__STDC_CONSTANT_MACROS', ]
 REL_CFLAGS = ['-O2']
 REL_CCFLAGS = ['-O2']
 ##BF_DEPEND = True
similarity index 95%
rename from config/linuxcross-config.py
rename to build_files/scons/config/linuxcross-config.py
index 0f8a15a..1650201 100644 (file)
@@ -65,7 +65,7 @@ WITH_BF_DDS = True
 WITH_BF_JPEG = True
 BF_JPEG = LIBDIR + '/jpeg'
 BF_JPEG_INC = '${BF_JPEG}/include'
-BF_JPEG_LIB = 'jpeg'
+BF_JPEG_LIB = 'libjpeg'
 BF_JPEG_LIBPATH = '${BF_JPEG}/lib'
 
 WITH_BF_PNG = True
@@ -83,7 +83,7 @@ BF_TIFF_LIBPATH = '${BF_TIFF}/lib'
 WITH_BF_ZLIB = True
 BF_ZLIB = LIBDIR + '/zlib'
 BF_ZLIB_INC = '${BF_ZLIB}/include'
-#BF_ZLIB_LIB = 'z'
+BF_ZLIB_LIB = 'libz'
 BF_ZLIB_LIBPATH = '${BF_ZLIB}/lib'
 
 WITH_BF_INTERNATIONAL = True
@@ -151,11 +151,9 @@ BF_OPENGL = 'C:\\MingW'
 BF_OPENGL_INC = '${BF_OPENGL}/include'
 BF_OPENGL_LIBINC = '${BF_OPENGL}/lib'
 BF_OPENGL_LIB = 'opengl32 glu32'
-BF_OPENGL_LIB_STATIC = [ '${BF_OPENGL}/lib/libGL.a', '${BF_OPENGL}/lib/libGLU.a',
-             '${BF_OPENGL}/lib/libXmu.a', '${BF_OPENGL}/lib/libXext.a',
-             '${BF_OPENGL}/lib/libX11.a', '${BF_OPENGL}/lib/libXi.a' ]
+BF_OPENGL_LIB_STATIC = [ '${BF_OPENGL}/lib/libGL.a', '${BF_OPENGL}/lib/libGLU.a']
 
-WITH_BF_OPENMP = True
+WITH_BF_OPENMP = False
 BF_OPENMP = LIBDIR + '/gcc/gomp'
 BF_OPENMP_INC = '${BF_OPENMP}/include'
 BF_OPENMP_LIBPATH = '${BF_OPENMP}/lib'
@@ -171,7 +169,7 @@ BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader Open
 BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib ${BF_ICONV_LIBPATH}'
 
 #Ray trace optimization
-WITH_BF_RAYOPTIMIZATION = False
+WITH_BF_RAYOPTIMIZATION = True
 BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse']
 
 CCFLAGS = [ '-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
similarity index 99%
rename from config/win32-mingw-config.py
rename to build_files/scons/config/win32-mingw-config.py
index 141658d..f8b6778 100644 (file)
@@ -64,7 +64,7 @@ WITH_BF_DDS = True
 WITH_BF_JPEG = True
 BF_JPEG = LIBDIR + '/jpeg'
 BF_JPEG_INC = '${BF_JPEG}/include'
-BF_JPEG_LIB = 'jpeg'
+BF_JPEG_LIB = 'liblibjpeg'
 BF_JPEG_LIBPATH = '${BF_JPEG}/lib'
 
 WITH_BF_PNG = True
@@ -82,6 +82,7 @@ BF_TIFF_LIBPATH = '${BF_TIFF}/lib'
 WITH_BF_ZLIB = True
 BF_ZLIB = LIBDIR + '/zlib'
 BF_ZLIB_INC = '${BF_ZLIB}/include'
+BF_ZLIB_LIB = 'libz'
 BF_ZLIB_LIBPATH = '${BF_ZLIB}/lib'
 
 WITH_BF_INTERNATIONAL = True
similarity index 98%
rename from config/win32-vc-config.py
rename to build_files/scons/config/win32-vc-config.py
index b376624..ce34737 100644 (file)
@@ -139,18 +139,18 @@ BF_FFTW3_LIBPATH = '${BF_FFTW3}/lib'
 WITH_BF_REDCODE = False  
 BF_REDCODE_INC = '#extern'
 
-WITH_BF_COLLADA = False
+WITH_BF_COLLADA = True
 BF_COLLADA = '#source/blender/collada'
 BF_COLLADA_INC = '${BF_COLLADA}'
 BF_COLLADA_LIB = 'bf_collada'
 
 BF_OPENCOLLADA = LIBDIR + '/opencollada'
 BF_OPENCOLLADA_INC = '${BF_OPENCOLLADA}/include'
-BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser UTF MathMLSolver xml2 pcre buffer ftoa'
+BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser MathMLSolver xml2 pcre buffer ftoa'
 BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib'
 
 #Ray trace optimization
-WITH_BF_RAYOPTIMIZATION = False
+WITH_BF_RAYOPTIMIZATION = True
 BF_RAYOPTIMIZATION_SSE_FLAGS = ['/arch:SSE']
 
 WITH_BF_STATICOPENGL = False
similarity index 98%
rename from config/win64-vc-config.py
rename to build_files/scons/config/win64-vc-config.py
index c1cbb7c..46b9034 100644 (file)
@@ -152,18 +152,18 @@ BF_FFTW3_LIBPATH = '${BF_FFTW3}/lib'
 WITH_BF_REDCODE = False  
 BF_REDCODE_INC = '#extern'
 
-WITH_BF_COLLADA = False
+WITH_BF_COLLADA = True
 BF_COLLADA = '#source/blender/collada'
 BF_COLLADA_INC = '${BF_COLLADA}'
 BF_COLLADA_LIB = 'bf_collada'
 
 BF_OPENCOLLADA = LIBDIR + '/opencollada'
 BF_OPENCOLLADA_INC = '${BF_OPENCOLLADA}/include'
-BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser UTF MathMLSolver xml2 pcre'
+BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser MathMLSolver xml2 pcre buffer ftoa'
 BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib'
 
 #Ray trace optimization
-WITH_BF_RAYOPTIMIZATION = False
+WITH_BF_RAYOPTIMIZATION = True
 BF_RAYOPTIMIZATION_SSE_FLAGS = ['/arch:SSE','/arch:SSE2']
 
 WITH_BF_STATICOPENGL = False
similarity index 94%
rename from tools/Blender.py
rename to build_files/scons/tools/Blender.py
index 69f6850..1195b00 100644 (file)
@@ -31,6 +31,8 @@ import SCons.Builder
 import SCons.Tool
 import bcolors
 bc = bcolors.bcolors()
+import btools
+VERSION = btools.VERSION
 
 Split = SCons.Util.Split
 Action = SCons.Action.Action
@@ -119,8 +121,9 @@ def setup_staticlibs(lenv):
        ]
 
        libincs = []
-       if lenv['OURPLATFORM'] != 'linuxcross':
-               libincs.append('/usr/lib')
+
+       if lenv['WITH_BF_FFMPEG']:
+               libincs += Split(lenv['BF_FFMPEG_LIBPATH'])
 
        libincs.extend([
                lenv['BF_OPENGL_LIBPATH'],
@@ -136,8 +139,6 @@ def setup_staticlibs(lenv):
                libincs += Split(lenv['BF_PYTHON_LIBPATH'])
        if lenv['WITH_BF_SDL']:
                libincs += Split(lenv['BF_SDL_LIBPATH'])
-       if lenv['WITH_BF_FFMPEG']:
-               libincs += Split(lenv['BF_FFMPEG_LIBPATH'])
        if lenv['WITH_BF_JACK']:
                libincs += Split(lenv['BF_JACK_LIBPATH'])
        if lenv['WITH_BF_SNDFILE']:
@@ -146,6 +147,8 @@ def setup_staticlibs(lenv):
                libincs += Split(lenv['BF_OPENEXR_LIBPATH'])
                if lenv['WITH_BF_STATICOPENEXR']:
                        statlibs += Split(lenv['BF_OPENEXR_LIB_STATIC'])
+       if lenv['WITH_BF_LCMS']:
+               libincs += Split(lenv['BF_LCMS_LIBPATH'])
        if lenv['WITH_BF_TIFF']:
                libincs += Split(lenv['BF_TIFF_LIBPATH'])
        if lenv['WITH_BF_FFTW3']:
@@ -177,6 +180,9 @@ def setup_staticlibs(lenv):
                if lenv['OURPLATFORM'] == 'linuxcross':
                        libincs += Split(lenv['BF_OPENMP_LIBPATH'])
 
+       # setting this last so any overriding of manually libs could be handled
+       if lenv['OURPLATFORM'] not in ('win32-vc', 'win32-mingw', 'win64-vc', 'linuxcross'):
+               libincs.append('/usr/lib')
 
        return statlibs, libincs
 
@@ -356,7 +362,11 @@ class CompZipFile(zipfile.ZipFile):
        """Partial copy of python2.6's zipfile.ZipFile (see http://www.python.org)
        to get a extractall() that works on py2.5 and probably earlier distributions."""
        def __init__(self, file, mode="r", compression=zipfile.ZIP_STORED, allowZip64=False):
-               zipfile.ZipFile.__init__(self, file, mode, compression, allowZip64)
+               if sys.version_info < (2, 6):
+                       zipfile.ZipFile.__init__(self, file, mode, compression)
+               else:
+                       zipfile.ZipFile.__init__(self, file, mode, compression, allowZip64)
+
                if not hasattr(self,"extractall"): # use our method 
                        print "Debug: Using comp_extractall!"
                        self.extractall= self.comp_extractall
@@ -458,7 +468,7 @@ def WinPyBundle(target=None, source=None, env=None):
        py_target = env.subst( env['BF_INSTALLDIR'] )
        if py_target[0]=='#':
                py_target=py_target[1:]
-       py_target+= '/.blender/python/lib/' 
+       py_target = os.path.join(py_target, VERSION, 'python', 'lib')
        def printexception(func,path,ex):
                if os.path.exists(path): #do not report if path does not exist. eg on a fresh build.
                        print str(func) + ' failed on ' + str(path)
@@ -513,27 +523,27 @@ def AppIt(target=None, source=None, env=None):
        commands.getoutput(cmd)
        cmd = 'cp %s/%s %s/%s.app/Contents/MacOS/%s'%(builddir, binary,builddir, binary, binary)
        commands.getoutput(cmd)
-       cmd = 'mkdir %s/%s.app/Contents/MacOS/.blender/'%(builddir, binary)
+       cmd = 'mkdir %s/%s.app/Contents/MacOS/%s/'%(builddir, binary, VERSION)
 #      print cmd
        commands.getoutput(cmd)
-       cmd = builddir + '/%s.app/Contents/MacOS/.blender'%binary
+       cmd = builddir + '/%s.app/Contents/MacOS/%s'%(binary,VERSION)
        shutil.copy(bldroot + '/bin/.blender/.bfont.ttf', cmd)
        shutil.copy(bldroot + '/bin/.blender/.Blanguages', cmd)
-       cmd = 'cp -R %s/bin/.blender/locale %s/%s.app/Contents/Resources/'%(bldroot,builddir,binary)
-       commands.getoutput(cmd) 
-       cmd = 'cp -R %s/bin/.blender/locale %s/%s.app/Contents/MacOS/.blender/'%(bldroot,builddir,binary)
-       commands.getoutput(cmd) 
-       cmd = 'cp %s/bin/.blender/.Blanguages %s/%s.app/Contents/Resources/'%(bldroot,builddir,binary)
-       commands.getoutput(cmd) 
-       cmd = 'mkdir %s/%s.app/Contents/MacOS/.blender/python/'%(builddir,binary)
-       commands.getoutput(cmd) 
-       cmd = 'unzip -q %s/release/%s -d %s/%s.app/Contents/MacOS/.blender/python/'%(libdir,python_zip,builddir,binary)
+       cmd = 'cp -R %s/bin/%s/locale %s/%s.app/Contents/Resources/'%(bldroot,VERSION,builddir,binary)
+       commands.getoutput(cmd)
+       cmd = 'cp -R %s/bin/%s/locale %s/%s.app/Contents/MacOS/%s/'%(bldroot,VERSION,builddir,binary,VERSION)
+       commands.getoutput(cmd)
+       cmd = 'cp %s/bin/%s/.Blanguages %s/%s.app/Contents/Resources/'%(bldroot,VERSION,builddir,binary)
+       commands.getoutput(cmd)
+       cmd = 'mkdir %s/%s.app/Contents/MacOS/%s/python/'%(builddir,binary, VERSION)
+       commands.getoutput(cmd)
+       cmd = 'unzip -q %s/release/%s -d %s/%s.app/Contents/MacOS/%s/python/'%(libdir,python_zip,builddir,binary,VERSION)
        commands.getoutput(cmd) 
-       cmd = 'cp -R %s/release/scripts %s/%s.app/Contents/MacOS/.blender/'%(bldroot,builddir,binary)
+       cmd = 'cp -R %s/release/scripts %s/%s.app/Contents/MacOS/%s/'%(bldroot,builddir,binary,VERSION)
        commands.getoutput(cmd)
-       cmd = 'cp -R %s/release/ui %s/%s.app/Contents/MacOS/.blender/'%(bldroot,builddir,binary)
+       cmd = 'cp -R %s/release/ui %s/%s.app/Contents/MacOS/%s/'%(bldroot,builddir,binary,VERSION)
        commands.getoutput(cmd)
-       cmd = 'cp -R %s/release/io %s/%s.app/Contents/MacOS/.blender/'%(bldroot,builddir,binary)
+       cmd = 'cp -R %s/release/io %s/%s.app/Contents/MacOS/%s/'%(bldroot,builddir,binary,VERSION)
        commands.getoutput(cmd)
        cmd = 'chmod +x  %s/%s.app/Contents/MacOS/%s'%(builddir,binary, binary)
        commands.getoutput(cmd)
@@ -551,7 +561,7 @@ def my_unixpybundle_print(target, source, env):
 
 def UnixPyBundle(target=None, source=None, env=None):
        # Any Unix except osx
-       #-- .blender/python/lib/python3.1
+       #-- VERSION/python/lib/python3.1
        
        import commands
        
@@ -560,7 +570,7 @@ def UnixPyBundle(target=None, source=None, env=None):
                commands.getoutput(cmd)
        
        if env['WITH_BF_FHS']:  dir = os.path.join(env['BF_INSTALLDIR'], 'share', 'blender', env['BF_VERSION']) # BLENDERPATH
-       else:                                   dir = os.path.join(env['BF_INSTALLDIR'], '.blender')
+       else:                                   dir = os.path.join(env['BF_INSTALLDIR'], VERSION)
        
        py_src =        env.subst( env['BF_PYTHON_LIBPATH'] + '/python'+env['BF_PYTHON_VERSION'] )
        py_target =     env.subst( dir + '/python/lib/python'+env['BF_PYTHON_VERSION'] )
similarity index 78%
rename from tools/btools.py
rename to build_files/scons/tools/btools.py
index e76ada3..03a1a0f 100644 (file)
@@ -1,4 +1,3 @@
-
 import os
 import os.path
 import SCons.Options
@@ -16,6 +15,8 @@ import sys
 Variables = SCons.Variables
 BoolVariable = SCons.Variables.BoolVariable
 
+VERSION = '2.52' # This is used in creating the local config directories
+
 def print_arguments(args, bc):
     if len(args):
         for k,v in args.iteritems():
@@ -73,7 +74,7 @@ def validate_arguments(args, bc):
             'BF_FANCY', 'BF_QUIET', 'BF_LINE_OVERWRITE',
             'BF_X264_CONFIG',
             'BF_XVIDCORE_CONFIG',
-            'WITH_BF_LCMS', 'BF_LCMS_LIB',
+            'WITH_BF_LCMS', 'BF_LCMS', 'BF_LCMS_INC', 'BF_LCMS_LIB', 'BF_LCMS_LIBPATH',
             'WITH_BF_DOCS',
             'BF_NUMJOBS',
             'BF_MSVS',
@@ -82,7 +83,8 @@ def validate_arguments(args, bc):
             'BF_GHOST_DEBUG',
             'WITH_BF_RAYOPTIMIZATION',
             'BF_RAYOPTIMIZATION_SSE_FLAGS',
-            'BF_NO_ELBEEM'
+            'BF_NO_ELBEEM',
+            'BF_VCREDIST' # Windows-only, and useful only when creating installer
             ]
     
     # Have options here that scons expects to be lists
@@ -261,12 +263,18 @@ def read_opts(env, cfg, args):
         ('BF_PNG_LIB', 'PNG library', ''),
         ('BF_PNG_LIBPATH', 'PNG library path', ''),
 
-       (BoolVariable('WITH_BF_TIFF', 'Use TIFF if true', True)),
+        (BoolVariable('WITH_BF_TIFF', 'Use TIFF if true', True)),
         ('BF_TIFF', 'TIFF base path', ''),
         ('BF_TIFF_INC', 'TIFF include path', ''),
         ('BF_TIFF_LIB', 'TIFF library', ''),
         ('BF_TIFF_LIBPATH', 'TIFF library path', ''),
 
+        (BoolVariable('WITH_BF_LCMS', 'Enable color correction with lcms', False)),
+        ('BF_LCMS', 'LCMS base path', ''),
+        ('BF_LCMS_INC', 'LCMS include path', ''),
+        ('BF_LCMS_LIB', 'LCMS library', ''),
+        ('BF_LCMS_LIBPATH', 'LCMS library path', ''),
+
         (BoolVariable('WITH_BF_ZLIB', 'Use ZLib if true', True)),
         ('BF_ZLIB', 'ZLib base path', ''),
         ('BF_ZLIB_INC', 'ZLib include path', ''),
@@ -418,9 +426,6 @@ def read_opts(env, cfg, args):
         (BoolVariable('WITH_BF_LZO', 'Enable fast LZO pointcache compression', True)),
         (BoolVariable('WITH_BF_LZMA', 'Enable best LZMA pointcache compression', True)),
         
-        (BoolVariable('WITH_BF_LCMS', 'Enable color correction with lcms', False)),
-        ('BF_LCMS_LIB', 'LCMSlibrary', 'lcms'),
-
         ('BF_X264_CONFIG', 'configuration flags for x264', ''),
         ('BF_XVIDCORE_CONFIG', 'configuration flags for xvidcore', ''),
         (BoolVariable('WITH_BF_DOCS', 'Generate API documentation', False)),
@@ -437,36 +442,60 @@ def read_opts(env, cfg, args):
         (BoolVariable('BF_GHOST_DEBUG', 'Make GHOST print events and info to stdout. (very verbose)', False)),
         
         (BoolVariable('WITH_BF_RAYOPTIMIZATION', 'Enable raytracer SSE/SIMD optimization.', False)),
-        ('BF_RAYOPTIMIZATION_SSE_FLAGS', 'SSE flags', '')
+        ('BF_RAYOPTIMIZATION_SSE_FLAGS', 'SSE flags', ''),
+        ('BF_VCREDIST', 'Full path to vcredist', '')
     ) # end of opts.AddOptions()
 
     return localopts
 
 def NSIS_print(target, source, env):
-    return "Creating NSIS installer for Blender 3D"
+    return "Creating NSIS installer for Blender"
 
 def NSIS_Installer(target=None, source=None, env=None):
+    print "="*35
 
-    if env['OURPLATFORM'] != 'win32-vc' and env['OURPLATFORM'] != 'win32-mingw':
+    if env['OURPLATFORM'] not in ('win32-vc', 'win32-mingw', 'win64-vc'):
         print "NSIS installer is only available on Windows."
         Exit()
-        
+    if env['OURPLATFORM'] == 'win32-vc':
+        bitness = '32'
+    elif env['OURPLATFORM'] == 'win64-vc':
+        bitness = '64'
+    else:
+        bitness = '-mingw'
+
     start_dir = os.getcwd()
-    rel_dir = start_dir + "\\release\\windows\\installer\\"
-    install_base_dir = start_dir + "\\"
-    
-    if not os.path.exists(install_base_dir+env['BF_INSTALLDIR']+'/plugins/include'):
-        os.mkdir(install_base_dir+env['BF_INSTALLDIR']+'/plugins/include')
-        
-    for f in glob.glob('source/blender/blenpluginapi/*.h'):
-        shutil.copy(f,install_base_dir+env['BF_INSTALLDIR']+'/plugins/include')
+    rel_dir = os.path.join(start_dir,'release','windows','installer')
+    install_base_dir = start_dir + os.sep
+
+    bf_installdir = os.path.join(os.getcwd(),env['BF_INSTALLDIR'])
+    bf_installdir = os.path.normpath(bf_installdir)
 
-    shutil.copy('source/blender/blenpluginapi/plugin.def',install_base_dir+env['BF_INSTALLDIR']+'/plugins/include/')
+    doneroot = False
+    rootdirconts = []
+    datafiles = ''
+    l = len(bf_installdir)
+    
+    for dp,dn,df in os.walk(bf_installdir):
+        if not doneroot:
+            for f in df:
+                rootdirconts.append(os.path.join(dp,f))
+            doneroot = True
+        else:
+            if len(df)>0:
+                dp_tmp = dp[l:]
+                if dp_tmp.find('python\\lib') > -1:
+                    datafiles += "\n" +r'SetOutPath $INSTDIR'+dp[l:]+"\n\n"
+                else:
+                    datafiles += "\n"+r'SetOutPath $BLENDERHOME'+dp[l:]+"\n\n"
+
+                for f in df:
+                    outfile = os.path.join(dp,f)
+                    datafiles += '  File '+outfile + "\n"
     
     os.chdir("release")
     v = open("VERSION")
     version = v.read()[:-1]    
-    shortver = version.split('.')[0] + version.split('.')[1]
     v.close()
 
     #### change to suit install dir ####
@@ -476,149 +505,50 @@ def NSIS_Installer(target=None, source=None, env=None):
 
     ns = open("00.sconsblender.nsi","r")
 
-
     ns_cnt = str(ns.read())
     ns.close()
 
-    # set Python version we compile against
-    ns_cnt = string.replace(ns_cnt, "[PYTHON_VERSION]", env['BF_PYTHON_VERSION'])
+    # var replacements
+    ns_cnt = string.replace(ns_cnt, "[DISTDIR]", os.path.normpath(inst_dir+os.sep))
+    ns_cnt = string.replace(ns_cnt, "[VERSION]", version)
+    ns_cnt = string.replace(ns_cnt, "[SHORTVERSION]", VERSION)
+    ns_cnt = string.replace(ns_cnt, "[RELDIR]", os.path.normpath(rel_dir))
+    ns_cnt = string.replace(ns_cnt, "[BITNESS]", bitness)
 
     # do root
     rootlist = []
-    rootdir = os.listdir(inst_dir+"\\")
-    for rootitem in rootdir:
-        if os.path.isdir(inst_dir+"\\"+ rootitem) == 0:
-            rootlist.append("File \"" + os.path.normpath(inst_dir) + "\\" + rootitem+"\"")
+    for rootitem in rootdirconts:
+        rootlist.append("File \"" + rootitem + "\"")
     rootstring = string.join(rootlist, "\n  ")
+    rootstring = rootstring
     rootstring += "\n\n"
     ns_cnt = string.replace(ns_cnt, "[ROOTDIRCONTS]", rootstring)
 
+
     # do delete items
     delrootlist = []
-    for rootitem in rootdir:
-        if os.path.isdir(inst_dir + rootitem) == 0:
-            delrootlist.append("Delete $INSTDIR\\" + rootitem)
+    for rootitem in rootdirconts:
+        delrootlist.append("Delete $INSTDIR\\" + rootitem[l+1:])
     delrootstring = string.join(delrootlist, "\n ")
     delrootstring += "\n"
     ns_cnt = string.replace(ns_cnt, "[DELROOTDIRCONTS]", delrootstring)
 
-    # do scripts
-    scriptlist = []
-    scriptpath = "%s%s" % (inst_dir, "\\.blender\\scripts")
-    scriptdir = os.listdir(scriptpath)
-    for scriptitem in scriptdir:
-        scriptfile = "%s\\%s" % (scriptpath, scriptitem)
-        if os.path.isdir(scriptfile) == 0:
-            scriptfile = os.path.normpath(scriptfile)
-            scriptlist.append("File \"%s\"" % scriptfile)
-    scriptstring = string.join(scriptlist, "\n  ")
-    scriptstring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[SCRIPTCONTS]", scriptstring)
-
-    # do scripts\bpymodules
-    bpymodlist = []
-    bpymodpath = "%s%s" % (inst_dir, "\\.blender\\scripts\\bpymodules")
-    bpymoddir = os.listdir(bpymodpath)
-
-    for bpymoditem in bpymoddir:
-        bpymodfile = "%s\\%s" % (bpymodpath, bpymoditem)
-        if os.path.isdir(bpymodfile) == 0:
-            bpymodfile = os.path.normpath(bpymodfile)
-            bpymodlist.append("File \"%s\"" % bpymodfile)
-    bpymodstring = string.join(bpymodlist, "\n  ")
-    bpymodstring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[SCRIPTMODCONTS]", bpymodstring)
-
-    # do scripts\bpymodules\colladaimex
-    colladalist = []
-    bpymodpath = "%s%s" % (inst_dir, "\\.blender\\scripts\\bpymodules\\ColladaImEx")
-    bpymoddir = os.listdir(bpymodpath)
-
-    for bpymoditem in bpymoddir:
-        bpymodfile = "%s\\%s" % (bpymodpath, bpymoditem)
-        if os.path.isdir(bpymodfile) == 0:
-            bpymodfile=os.path.normpath(bpymodfile)
-            colladalist.append("File \"%s\"" % bpymodfile)
-    bpymodstring = string.join(colladalist, "\n  ")
-    bpymodstring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[SCRIPTMODCOLLADACONT]", bpymodstring)
-
-    # do scripts\bpydata
-    bpydatalist = []
-    bpydatapath = "%s%s" % (inst_dir, "\\.blender\\scripts\\bpydata")
-    bpydatadir = os.listdir(bpydatapath)
-    for bpydataitem in bpydatadir:
-        bpydatafile = "%s\\%s" % (bpydatapath, bpydataitem)
-        if os.path.isdir(bpydatafile) == 0:
-            bpydatalist.append("File \"%s\"" % bpydatafile)
-    bpydatastring = string.join(bpydatalist, "\n  ")
-    bpydatastring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[SCRIPTDATACONTS]", bpydatastring)
-
-    # do plugins\include
-    plugincludelist = []
-    plugincludepath = "%s%s" % (inst_dir, "\\plugins\\include")
-    plugincludedir = os.listdir(plugincludepath)
-    for plugincludeitem in plugincludedir:
-        plugincludefile = "%s\\%s" % (plugincludepath, plugincludeitem)
-        if os.path.isdir(plugincludefile) == 0:
-            if plugincludefile.find('.h') or plugincludefile.find('.DEF'):
-                plugincludefile = os.path.normpath(plugincludefile)
-                plugincludelist.append("File \"%s\"" % plugincludefile)
-    plugincludestring = string.join(plugincludelist, "\n  ")
-    plugincludestring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[PLUGINCONTS]", plugincludestring)
-
-    # do scripts\bpydata\config
-    cfglist = []
-    cfgpath = "%s%s" % (inst_dir, "\\.blender\\scripts\\bpydata\\config")
-    cfgdir = os.listdir(cfgpath)
-    for cfgitem in cfgdir:
-        cfgfile = "%s\\%s" % (cfgpath, cfgitem)
-        if os.path.isdir(cfgfile) == 0:
-            cfglist.append("File \"%s\"" % cfgfile)
-    cfgstring = string.join(cfglist, "\n  ")
-    cfgstring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[SCRIPTDATACFGCONTS]", cfgstring)
-
-    # do dotblender
-    dotblendlist = []
-    dotblenddir = os.listdir(inst_dir+"\\.blender")
-    for dotblenditem in dotblenddir:
-        if os.path.isdir(inst_dir + "\\.blender\\" + dotblenditem) == 0:
-            dotblendlist.append("File \"" + os.path.normpath(inst_dir) + "\\.blender\\" +
-            dotblenditem+"\"")
-    dotblendstring = string.join(dotblendlist, "\n  ")
-    dotblendstring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[DOTBLENDERCONTS]", dotblendstring)
-
-    # do language files
-    langlist = []
-    langfiles = []
-    langdir = os.listdir(inst_dir + "\\.blender\\locale")
-    for langitem in langdir:
-        if os.path.isdir(inst_dir + "\\.blender\\locale\\" + langitem) == 1:
-            langfiles.append("SetOutPath $BLENDERHOME\\.blender\\locale\\" + langitem + "\\LC_MESSAGES")
-            langfiles.append("File \"" + os.path.normpath(inst_dir) + "\\.blender\\locale\\"
-                    + langitem + "\\LC_MESSAGES\\blender.mo\"")
-    langstring = string.join(langfiles, "\n  ")
-    langstring += "\n\n"
-    ns_cnt = string.replace(ns_cnt, "[LANGUAGECONTS]", langstring)
+    ns_cnt = string.replace(ns_cnt, "[DODATAFILES]", datafiles)
 
-    # var replacements
-    ns_cnt = string.replace(ns_cnt, "DISTDIR", os.path.normpath(inst_dir+"\\"))
-    ns_cnt = string.replace(ns_cnt, "SHORTVER", shortver)
-    ns_cnt = string.replace(ns_cnt, "VERSION", version)
-    ns_cnt = string.replace(ns_cnt, "RELDIR", os.path.normpath(rel_dir))
+    # Setup vcredist part
+    vcredist = "File \""+env['BF_VCREDIST'] + "\"\n"
+    vcredist += "  ExecWait '\"$TEMP\\" + os.path.basename(env['BF_VCREDIST']) + "\" /q'\n"
+    vcredist += "  Delete \"$TEMP\\" + os.path.basename(env['BF_VCREDIST'])+"\""
+    ns_cnt = string.replace(ns_cnt, "[VCREDIST]", vcredist)
 
     tmpnsi = os.path.normpath(install_base_dir+os.sep+env['BF_BUILDDIR']+os.sep+"00.blender_tmp.nsi")
     new_nsis = open(tmpnsi, 'w')
     new_nsis.write(ns_cnt)
     new_nsis.close()
-    print "Preparing nsis file looks ok\n"
+    print "NSIS Installer script created"
 
     os.chdir(start_dir)
-    print "try to launch 'makensis' ...make sure it is on the path \n"
+    print "Launching 'makensis'"
 
     cmdline = "makensis " + "\""+tmpnsi+"\""
 
diff --git a/doc/blender.1 b/doc/blender.1
new file mode 100644 (file)
index 0000000..43ac563
--- /dev/null
@@ -0,0 +1,338 @@
+.TH "BLENDER" "1" "June 27, 2010" "Blender Blender 2\&.52 (sub 5) "
+
+.SH NAME
+blender \- a 3D modelling and rendering package
+.SH SYNOPSIS
+.B blender [args ...] [file] [args ...]
+.br
+.SH DESCRIPTION
+.PP
+.B blender
+is a 3D modelling and rendering package. It is the in-house software of a high quality animation studio, Blender has proven to be an extremely fast and versatile design instrument. The software has a personal touch, offering a unique approach to the world of Three Dimensions.
+
+Use Blender to create TV commercials, to make technical visualizations, business graphics, to do some morphing, or design user interfaces. You can easy build and manage complex environments. The renderer is versatile and extremely fast. All basic animation principles (curves & keys) are well implemented.
+
+http://www.blender.org
+.SH OPTIONS
+
+Blender 2.52 (sub 5) Build
+Usage: blender [args ...] [file] [args ...]
+.br
+.SS "Render Options:"
+
+.TP
+.B \-b or \-\-background <file>
+.br
+Load <file> in background (often used for UI\-less rendering)
+.br
+
+.TP
+.B \-a or \-\-render\-anim
+.br
+Render frames from start to end (inclusive)
+.br
+
+.TP
+.B \-S or \-\-scene <name>
+.br
+Set the active scene <name> for rendering
+.br
+
+.TP
+.B \-f or \-\-render\-frame <frame>
+.br
+Render frame <frame> and save it.
+.br
++<frame> start frame relative, \-<frame> end frame relative.
+.br
+
+.TP
+.B \-s or \-\-frame\-start <frame>
+.br
+Set start to frame <frame> (use before the \-a argument)
+.br
+
+.TP
+.B \-e or \-\-frame\-end <frame>
+.br
+Set end to frame <frame> (use before the \-a argument)
+.br
+
+.TP
+.B \-j or \-\-frame\-jump <frames>
+.br
+Set number of frames to step forward after each rendered frame
+.br
+
+.TP
+.B \-o or \-\-render\-output <path>
+.br
+Set the render path and file name.
+.br
+Use // at the start of the path to
+.br
+    render relative to the blend file.
+.br
+The # characters are replaced by the frame number, and used to define zero padding.
+.br
+    ani_##_test.png becomes ani_01_test.png
+.br
+    test\-######.png becomes test\-000001.png
+.br
+    When the filename does not contain #, The suffix #### is added to the filename
+.br
+The frame number will be added at the end of the filename.
+.br
+    eg: blender \-b foobar.blend \-o //render_ \-F PNG \-x 1 \-a
+.br
+    //render_ becomes //render_####, writing frames as //render_0001.png//
+.br
+
+.TP
+.B \-E or \-\-engine <engine>
+.br
+Specify the render engine
+.br
+use \-E help to list available engines
+.br
+
+.IP
+
+.SS "Format Options:"
+
+.TP
+.B \-F or \-\-render\-format <format>
+.br
+Set the render format, Valid options are...
+.br
+    TGA IRIS JPEG MOVIE IRIZ RAWTGA
+.br
+    AVIRAW AVIJPEG PNG BMP FRAMESERVER
+.br
+(formats that can be compiled into blender, not available on all systems)
+.br
+    HDR TIFF EXR MULTILAYER MPEG AVICODEC QUICKTIME CINEON DPX DDS
+.br
+
+.TP
+.B \-x or \-\-use\-extension <bool>
+.br
+Set option to add the file extension to the end of the file
+.br
+
+.TP
+.B \-t or \-\-threads <threads>
+.br
+Use amount of <threads> for rendering in background
+.br
+[1\-BLENDER_MAX_THREADS], 0 for systems processor count.
+.br
+
+.IP
+
+.SS "Animation Playback Options:"
+
+.TP
+.B \-a <options> <file(s)>
+.br
+Playback <file(s)>, only operates this way when not running in background.
+.br
+    \-p <sx> <sy> Open with lower left corner at <sx>, <sy>
+.br
+    \-m Read from disk (Don't buffer)
+.br
+    \-f <fps> <fps\-base> Specify FPS to start with
+.br
+    \-j <frame> Set frame step to <frame>
+.br
+
+.IP
+
+.SS "Window Options:"
+
+.TP
+.B \-w or \-\-window\-border
+.br
+Force opening with borders (default)
+.br
+
+.TP
+.B \-W or \-\-window\-borderless
+.br
+Force opening with without borders
+.br
+
+.TP
+.B \-p or \-\-window\-geometry <sx> <sy> <w> <h>
+.br
+Open with lower left corner at <sx>, <sy> and width and height as <w>, <h>
+.br
+
+.IP
+
+.SS "Game Engine Specific Options:"
+
+.TP
+.B \-g Game Engine specific options
+.br
+\-g fixedtime Run on 50 hertz without dropping frames
+.br
+\-g vertexarrays Use Vertex Arrays for rendering (usually faster)
+.br
+\-g nomipmap No Texture Mipmapping
+.br
+\-g linearmipmap Linear Texture Mipmapping instead of Nearest (default)
+.br
+
+.IP
+
+.SS "Misc Options:"
+
+.TP
+.B \-d or \-\-debug
+.br
+Turn debugging on
+.br
+
+.IP
+* Prints every operator call and their arguments
+.br
+* Disables mouse grab (to interact with a debugger in some cases)
+.br
+* Keeps python sys.stdin rather then setting it to None
+.br
+
+.TP
+.B \-\-debug\-fpe
+.br
+Enable floating point exceptions
+.br
+
+.IP
+
+.TP
+.B \-nojoystick
+.br
+Disable joystick support
+.br
+
+.TP
+.B \-noglsl
+.br
+Disable GLSL shading
+.br
+
+.TP
+.B \-noaudio
+.br
+Force sound system to None
+.br
+
+.TP
+.B \-setaudio
+.br
+Force sound system to a specific device
+.br
+NULL SDL OPENAL JACK
+.br
+
+.IP
+
+.TP
+.B \-h or \-\-help
+.br
+Print this help text and exit
+.br
+
+.IP
+
+.TP
+.B \-y or \-\-enable\-autoexec
+.br
+Enable automatic python script execution (default)
+.br
+
+.TP
+.B \-Y or \-\-disable\-autoexec
+.br
+Disable automatic python script execution (pydrivers, pyconstraints, pynodes)
+.br
+
+.IP
+
+.TP
+.B \-P or \-\-python <filename>
+.br
+Run the given Python script (filename or Blender Text)
+.br
+
+.TP
+.B \-\-python\-console
+.br
+Run blender with an interactive console
+.br
+
+.TP
+.B \-v or \-\-version
+.br
+Print Blender version and exit
+.br
+
+.TP
+.B \-\-
+.br
+Ends option processing, following arguments passed unchanged. Access via python's sys.argv
+.br
+
+.SS "Other Options:"
+
+.TP
+.B /?
+.br
+Print this help text and exit (windows only)
+.br
+
+.TP
+.B \-R
+.br
+Register .blend extension (windows only)
+.br
+
+.SS "Argument Parsing:"
+
+    arguments must be separated by white space. eg
+        "blender \-ba test.blend"
+    ...will ignore the 'a'
+        "blender \-b test.blend \-f8"
+    ...will ignore 8 because there is no space between the \-f and the frame value
+.br
+.SS "Argument Order:"
+
+Arguments are executed in the order they are given. eg
+        "blender \-\-background test.blend \-\-render\-frame 1 \-\-render\-output /tmp"
+    ...will not render to /tmp because '\-\-render\-frame 1' renders before the output path is set
+        "blender \-\-background \-\-render\-output /tmp test.blend \-\-render\-frame 1"
+    ...will not render to /tmp because loading the blend file overwrites the render output that was set
+        "blender \-\-background test.blend \-\-render\-output /tmp \-\-render\-frame 1" works as expected.
+.br
+.br
+.SH "ENVIRONMENT VARIABLES"
+  \fIHOME\fR Store files such as .blender/ .B.blend .Bfs .Blog here.
+  \fIBLENDERPATH\fR System directory to use for data files and scripts.
+                For this build of blender the default \fIBLENDERPATH\fR is...
+                "/usr/local/share/blender/2.5"
+                setting the \fIBLENDERPATH\fR will override this
+  \fITMP\fR or \fITMPDIR\fR Store temporary files here.
+  \fIPYTHONHOME\fR Path to the python directory, eg. /usr/lib/python.
+.br
+.br
+
+.br
+.SH SEE ALSO
+.B yafaray(1)
+
+.br
+.SH AUTHORS
+This manpage was written for a Debian GNU/Linux system by Daniel Mester
+<mester@uni-bremen.de> and updated by Cyril Brulebois
+<cyril.brulebois@enst-bretagne.fr> and Dan Eicher <dan@trollwerks.org>.
diff --git a/doc/blender.1.py b/doc/blender.1.py
new file mode 100644 (file)
index 0000000..c77e5cc
--- /dev/null
@@ -0,0 +1,134 @@
+#!/usr/bin/python
+
+# ##### 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.
+#
+# ##### END GPL LICENSE BLOCK #####
+
+# <pep8 compliant>
+
+import subprocess
+import os
+
+import time
+import datetime
+
+
+def man_format(data):
+    data = data.replace("-", "\\-")
+    data = data.replace("\t", "    ")
+    # data = data.replace("$", "\\fI")
+    
+    data_ls = []
+    for w in data.split():
+        if w.startswith("$"):
+            w = "\\fI" + w[1:] + "\\fR"
+           
+        data_ls.append(w)
+
+    data = data[:len(data) - len(data.lstrip())] + " ".join(data_ls)
+
+    return data
+
+
+blender_bin = os.path.join(os.path.dirname(__file__), "../blender")
+
+blender_help = subprocess.Popen([blender_bin, "--help"], stdout=subprocess.PIPE).communicate()[0].decode()
+
+blender_version = subprocess.Popen([blender_bin, "--version"], stdout=subprocess.PIPE).communicate()[0].decode().strip()
+blender_version = blender_version.split("Build")[0]
+
+date_string = datetime.date.fromtimestamp(time.time()).strftime("%B %d, %Y")
+
+filepath = __file__.replace(".py", "")
+
+file = open(filepath, "w")
+
+fw = file.write
+
+fw('.TH "BLENDER" "1" "%s" "Blender %s"\n' % (date_string, blender_version.replace(".", "\\&.")))
+
+fw('''
+.SH NAME
+blender \- a 3D modelling and rendering package''')
+
+fw('''
+.SH SYNOPSIS
+.B blender [args ...] [file] [args ...]''')
+
+fw('''
+.br
+.SH DESCRIPTION
+.PP
+.B blender
+is a 3D modelling and rendering package. It is the in-house software of a high quality animation studio, Blender has proven to be an extremely fast and versatile design instrument. The software has a personal touch, offering a unique approach to the world of Three Dimensions.
+
+Use Blender to create TV commercials, to make technical visualizations, business graphics, to do some morphing, or design user interfaces. You can easy build and manage complex environments. The renderer is versatile and extremely fast. All basic animation principles (curves & keys) are well implemented.
+
+http://www.blender.org''')
+
+fw('''
+.SH OPTIONS''')
+
+fw("\n\n")
+
+lines = [line.rstrip() for line in blender_help.split("\n")]
+
+while lines:
+    l = lines.pop(0)
+    if l.startswith("Environment Variables:"):
+        fw('.SH "ENVIRONMENT VARIABLES"\n') 
+    elif l.endswith(":"): # one line
+        fw('.SS "%s"\n\n' % l) 
+    elif l.startswith("-") or l.startswith("/"): # can be multi line
+
+        fw('.TP\n')
+        fw('.B %s\n' % man_format(l))
+        
+        while lines:
+            # line with no 
+            if lines[0].strip() and len(lines[0].lstrip()) == len(lines[0]): # no white space
+                break
+
+            if not l: # second blank line
+                fw('.IP\n')
+            else:
+                fw('.br\n')
+
+            l = lines.pop(0)
+            l = l[1:] # remove first whitespace (tab)
+
+            fw('%s\n' % man_format(l))
+    
+    else:
+        if not l.strip():
+            fw('.br\n')
+        else:
+            fw('%s\n' % man_format(l))
+
+# footer
+
+fw('''
+.br
+.SH SEE ALSO
+.B yafaray(1)
+
+.br
+.SH AUTHORS
+This manpage was written for a Debian GNU/Linux system by Daniel Mester
+<mester@uni-bremen.de> and updated by Cyril Brulebois
+<cyril.brulebois@enst-bretagne.fr> and Dan Eicher <dan@trollwerks.org>.
+''')
index 2014092..3cb7bed 100644 (file)
@@ -2702,7 +2702,7 @@ typedef GLenum (GLAPIENTRY * PFNGLCHECKFRAMEBUFFERSTATUSPROC) (GLenum target);
 typedef void (GLAPIENTRY * PFNGLDELETEFRAMEBUFFERSPROC) (GLsizei n, const GLuint* framebuffers);
 typedef void (GLAPIENTRY * PFNGLDELETERENDERBUFFERSPROC) (GLsizei n, const GLuint* renderbuffers);
 typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERRENDERBUFFERPROC) (GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
-typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTURLAYERPROC) (GLenum target,GLenum attachment, GLuint texture,GLint level,GLint layer);
+typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTURELAYERPROC) (GLenum target,GLenum attachment, GLuint texture,GLint level,GLint layer);
 typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTURE1DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
 typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTURE2DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
 typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTURE3DPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint layer);
@@ -2723,7 +2723,7 @@ typedef void (GLAPIENTRY * PFNGLRENDERBUFFERSTORAGEMULTISAMPLEPROC) (GLenum targ
 #define glDeleteFramebuffers GLEW_GET_FUN(__glewDeleteFramebuffers)
 #define glDeleteRenderbuffers GLEW_GET_FUN(__glewDeleteRenderbuffers)
 #define glFramebufferRenderbuffer GLEW_GET_FUN(__glewFramebufferRenderbuffer)
-#define glFramebufferTexturLayer GLEW_GET_FUN(__glewFramebufferTexturLayer)
+#define glFramebufferTextureLayer GLEW_GET_FUN(__glewFramebufferTextureLayer)
 #define glFramebufferTexture1D GLEW_GET_FUN(__glewFramebufferTexture1D)
 #define glFramebufferTexture2D GLEW_GET_FUN(__glewFramebufferTexture2D)
 #define glFramebufferTexture3D GLEW_GET_FUN(__glewFramebufferTexture3D)
@@ -8288,7 +8288,6 @@ typedef void (GLAPIENTRY * PFNGLGETVIDEOUI64VNVPROC) (GLuint video_slot, GLenum
 typedef void (GLAPIENTRY * PFNGLGETVIDEOUIVNVPROC) (GLuint video_slot, GLenum pname, GLuint* params);
 typedef void (GLAPIENTRY * PFNGLPRESENTFRAMEDUALFILLNVPROC) (GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLenum target1, GLuint fill1, GLenum target2, GLuint fill2, GLenum target3, GLuint fill3);
 typedef void (GLAPIENTRY * PFNGLPRESENTFRAMEKEYEDNVPROC) (GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLuint key0, GLenum target1, GLuint fill1, GLuint key1);
-typedef void (GLAPIENTRY * PFNGLVIDEOPARAMETERIVNVPROC) (GLuint video_slot, GLenum pname, const GLint* params);
 
 #define glGetVideoi64vNV GLEW_GET_FUN(__glewGetVideoi64vNV)
 #define glGetVideoivNV GLEW_GET_FUN(__glewGetVideoivNV)
@@ -10563,7 +10562,7 @@ GLEW_FUN_EXPORT PFNGLCHECKFRAMEBUFFERSTATUSPROC __glewCheckFramebufferStatus;
 GLEW_FUN_EXPORT PFNGLDELETEFRAMEBUFFERSPROC __glewDeleteFramebuffers;
 GLEW_FUN_EXPORT PFNGLDELETERENDERBUFFERSPROC __glewDeleteRenderbuffers;
 GLEW_FUN_EXPORT PFNGLFRAMEBUFFERRENDERBUFFERPROC __glewFramebufferRenderbuffer;
-GLEW_FUN_EXPORT PFNGLFRAMEBUFFERTEXTURLAYERPROC __glewFramebufferTexturLayer;
+GLEW_FUN_EXPORT PFNGLFRAMEBUFFERTEXTURELAYERPROC __glewFramebufferTextureLayer;
 GLEW_FUN_EXPORT PFNGLFRAMEBUFFERTEXTURE1DPROC __glewFramebufferTexture1D;
 GLEW_FUN_EXPORT PFNGLFRAMEBUFFERTEXTURE2DPROC __glewFramebufferTexture2D;
 GLEW_FUN_EXPORT PFNGLFRAMEBUFFERTEXTURE3DPROC __glewFramebufferTexture3D;
@@ -11612,7 +11611,6 @@ GLEW_FUN_EXPORT PFNGLGETVIDEOUI64VNVPROC __glewGetVideoui64vNV;
 GLEW_FUN_EXPORT PFNGLGETVIDEOUIVNVPROC __glewGetVideouivNV;
 GLEW_FUN_EXPORT PFNGLPRESENTFRAMEDUALFILLNVPROC __glewPresentFrameDualFillNV;
 GLEW_FUN_EXPORT PFNGLPRESENTFRAMEKEYEDNVPROC __glewPresentFrameKeyedNV;
-GLEW_FUN_EXPORT PFNGLVIDEOPARAMETERIVNVPROC __glewVideoParameterivNV;
 
 GLEW_FUN_EXPORT PFNGLPRIMITIVERESTARTINDEXNVPROC __glewPrimitiveRestartIndexNV;
 GLEW_FUN_EXPORT PFNGLPRIMITIVERESTARTNVPROC __glewPrimitiveRestartNV;
index 24c6a72..1d947d3 100644 (file)
@@ -547,7 +547,7 @@ PFNGLCHECKFRAMEBUFFERSTATUSPROC __glewCheckFramebufferStatus = NULL;
 PFNGLDELETEFRAMEBUFFERSPROC __glewDeleteFramebuffers = NULL;
 PFNGLDELETERENDERBUFFERSPROC __glewDeleteRenderbuffers = NULL;
 PFNGLFRAMEBUFFERRENDERBUFFERPROC __glewFramebufferRenderbuffer = NULL;
-PFNGLFRAMEBUFFERTEXTURLAYERPROC __glewFramebufferTexturLayer = NULL;
+PFNGLFRAMEBUFFERTEXTURELAYERPROC __glewFramebufferTextureLayer = NULL;
 PFNGLFRAMEBUFFERTEXTURE1DPROC __glewFramebufferTexture1D = NULL;
 PFNGLFRAMEBUFFERTEXTURE2DPROC __glewFramebufferTexture2D = NULL;
 PFNGLFRAMEBUFFERTEXTURE3DPROC __glewFramebufferTexture3D = NULL;
@@ -1596,7 +1596,6 @@ PFNGLGETVIDEOUI64VNVPROC __glewGetVideoui64vNV = NULL;
 PFNGLGETVIDEOUIVNVPROC __glewGetVideouivNV = NULL;
 PFNGLPRESENTFRAMEDUALFILLNVPROC __glewPresentFrameDualFillNV = NULL;
 PFNGLPRESENTFRAMEKEYEDNVPROC __glewPresentFrameKeyedNV = NULL;
-PFNGLVIDEOPARAMETERIVNVPROC __glewVideoParameterivNV = NULL;
 
 PFNGLPRIMITIVERESTARTINDEXNVPROC __glewPrimitiveRestartIndexNV = NULL;
 PFNGLPRIMITIVERESTARTNVPROC __glewPrimitiveRestartNV = NULL;
@@ -2739,7 +2738,7 @@ static GLboolean _glewInit_GL_ARB_framebuffer_object (GLEW_CONTEXT_ARG_DEF_INIT)
   r = ((glDeleteFramebuffers = (PFNGLDELETEFRAMEBUFFERSPROC)glewGetProcAddress((const GLubyte*)"glDeleteFramebuffers")) == NULL) || r;
   r = ((glDeleteRenderbuffers = (PFNGLDELETERENDERBUFFERSPROC)glewGetProcAddress((const GLubyte*)"glDeleteRenderbuffers")) == NULL) || r;
   r = ((glFramebufferRenderbuffer = (PFNGLFRAMEBUFFERRENDERBUFFERPROC)glewGetProcAddress((const GLubyte*)"glFramebufferRenderbuffer")) == NULL) || r;
-  r = ((glFramebufferTexturLayer = (PFNGLFRAMEBUFFERTEXTURLAYERPROC)glewGetProcAddress((const GLubyte*)"glFramebufferTexturLayer")) == NULL) || r;
+  r = ((glFramebufferTextureLayer = (PFNGLFRAMEBUFFERTEXTURELAYERPROC)glewGetProcAddress((const GLubyte*)"glFramebufferTextureLayer")) == NULL) || r;
   r = ((glFramebufferTexture1D = (PFNGLFRAMEBUFFERTEXTURE1DPROC)glewGetProcAddress((const GLubyte*)"glFramebufferTexture1D")) == NULL) || r;
   r = ((glFramebufferTexture2D = (PFNGLFRAMEBUFFERTEXTURE2DPROC)glewGetProcAddress((const GLubyte*)"glFramebufferTexture2D")) == NULL) || r;
   r = ((glFramebufferTexture3D = (PFNGLFRAMEBUFFERTEXTURE3DPROC)glewGetProcAddress((const GLubyte*)"glFramebufferTexture3D")) == NULL) || r;
@@ -5303,7 +5302,6 @@ static GLboolean _glewInit_GL_NV_present_video (GLEW_CONTEXT_ARG_DEF_INIT)
   r = ((glGetVideouivNV = (PFNGLGETVIDEOUIVNVPROC)glewGetProcAddress((const GLubyte*)"glGetVideouivNV")) == NULL) || r;
   r = ((glPresentFrameDualFillNV = (PFNGLPRESENTFRAMEDUALFILLNVPROC)glewGetProcAddress((const GLubyte*)"glPresentFrameDualFillNV")) == NULL) || r;
   r = ((glPresentFrameKeyedNV = (PFNGLPRESENTFRAMEKEYEDNVPROC)glewGetProcAddress((const GLubyte*)"glPresentFrameKeyedNV")) == NULL) || r;
-  r = ((glVideoParameterivNV = (PFNGLVIDEOPARAMETERIVNVPROC)glewGetProcAddress((const GLubyte*)"glVideoParameterivNV")) == NULL) || r;
 
   return r;
 }
index fa630ce..1a7627c 100644 (file)
@@ -42,6 +42,7 @@ SET(SRC
        ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_ISystem.cpp
        ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_ModifierKeys.cpp
        ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_NDOFManager.cpp
+       ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_Path-api.cpp
        ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_Rect.cpp
        ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_System.cpp
        ${CMAKE_CURRENT_SOURCE_DIR}/intern/GHOST_TimerManager.cpp
index 346fa29..28fa72f 100644 (file)
@@ -264,7 +264,24 @@ extern int GHOST_DispatchEvents(GHOST_SystemHandle systemhandle);
 extern GHOST_TSuccess GHOST_AddEventConsumer(GHOST_SystemHandle systemhandle,
                                                                                          GHOST_EventConsumerHandle consumerhandle);
        
+/***************************************************************************************
+ ** Progress bar functionality
+ ***************************************************************************************/
 
+/**
+ * Sets the progress bar value displayed in the window/application icon
+ * @param windowhandle The handle to the window
+ * @param progress The progress % (0.0 to 1.0)
+ */
+extern GHOST_TSuccess GHOST_SetProgressBar(GHOST_WindowHandle windowhandle, float progress);
+
+/**
+ * Hides the progress bar in the icon
+ * @param windowhandle The handle to the window
+ */
+extern GHOST_TSuccess GHOST_EndProgressBar(GHOST_WindowHandle windowhandle);
+       
+       
 /***************************************************************************************
  ** N-degree of freedom device management functionality
  ***************************************************************************************/
@@ -819,20 +836,6 @@ extern GHOST_TUns8* GHOST_getClipboard(int selection);
  */
 extern void GHOST_putClipboard(GHOST_TInt8 *buffer, int selection);
 
-/**
- * Determine the base dir in which shared resources are located. It will first try to use
- * "unpack and run" path, then look for properly installed path, not including versioning.
- * @return Unsigned char string pointing to system dir (eg /usr/share/blender/).
- */
-extern const GHOST_TUns8* GHOST_getSystemDir();
-
-/**
- * Determine the base dir in which user configuration is stored, not including versioning.
- * If needed, it will create the base directory.
- * @return Unsigned char string pointing to user dir (eg ~/.blender/).
- */
-extern const GHOST_TUns8* GHOST_getUserDir();
-
 
 #ifdef __cplusplus
 }
index 8d80c74..47f142e 100644 (file)
@@ -370,12 +370,7 @@ public:
         */
        virtual void putClipboard(GHOST_TInt8 *buffer, bool selection) const = 0;
 
-       
-       /***************************************************************************************
-        ** Determine special paths.
-        ***************************************************************************************/
-
-       /**
+                       /**
         * Determine the base dir in which shared resources are located. It will first try to use
         * "unpack and run" path, then look for properly installed path, not including versioning.
         * @return Unsigned char string pointing to system dir (eg /usr/share/blender/).
@@ -389,6 +384,11 @@ public:
         */
        virtual const GHOST_TUns8* getUserDir() const = 0;
 
+       /**
+         * Determine the directory of the current binary
+         * @return Unsigned char string pointing to the binary dir
+         */
+        virtual const GHOST_TUns8* getBinaryDir() const = 0;
 protected:
        /**
         * Initialize the system.
index a024b2b..83757b1 100644 (file)
@@ -234,6 +234,21 @@ public:
         */
        virtual const GHOST_TabletData* GetTabletData() = 0;
        
+       /***************************************************************************************
+        ** Progress bar functionality
+        ***************************************************************************************/
+       
+       /**
+     * Sets the progress bar value displayed in the window/application icon
+        * @param progress The progress %
+        */
+       virtual GHOST_TSuccess setProgressBar(float progress) = 0;
+       
+       /**
+        * Hides the progress bar in the icon
+        */
+       virtual GHOST_TSuccess endProgressBar() = 0;
+       
        /***************************************************************************************
         ** Cursor management functionality
         ***************************************************************************************/
diff --git a/intern/ghost/GHOST_Path-api.h b/intern/ghost/GHOST_Path-api.h
new file mode 100644 (file)
index 0000000..c38a4e2
--- /dev/null
@@ -0,0 +1,63 @@
+/**
+ * $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 Blender Foundation.
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s): none yet.
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#ifndef        GHOST_PATH_API_H
+#define GHOST_PATH_API_H
+
+#include "GHOST_Types.h"
+
+#ifdef __cplusplus
+extern "C" { 
+#endif
+
+/**
+ * Determine the base dir in which shared resources are located. It will first try to use
+ * "unpack and run" path, then look for properly installed path, not including versioning.
+ * @return Unsigned char string pointing to system dir (eg /usr/share/blender/).
+ */
+extern const GHOST_TUns8* GHOST_getSystemDir();
+
+/**
+ * Determine the base dir in which user configuration is stored, not including versioning.
+ * @return Unsigned char string pointing to user dir (eg ~).
+ */
+extern const GHOST_TUns8* GHOST_getUserDir();
+
+
+/**
+ * Determine the dir in which the binary file is found.
+ * @return Unsigned char string pointing to binary dir (eg ~/usr/local/bin/).
+ */
+extern const GHOST_TUns8* GHOST_getBinaryDir();
+
+#ifdef __cplusplus
+} 
+#endif
+
+#endif
index 44b361d..839d85c 100644 (file)
@@ -248,6 +248,21 @@ GHOST_TSuccess GHOST_AddEventConsumer(GHOST_SystemHandle systemhandle, GHOST_Eve
        return system->addEventConsumer((GHOST_CallbackEventConsumer*)consumerhandle);
 }
 
+GHOST_TSuccess GHOST_SetProgressBar(GHOST_WindowHandle windowhandle,float progress)
+{
+       GHOST_IWindow* window = (GHOST_IWindow*) windowhandle;
+
+       return window->setProgressBar(progress);
+}
+
+GHOST_TSuccess GHOST_EndProgressBar(GHOST_WindowHandle windowhandle)
+{
+       GHOST_IWindow* window = (GHOST_IWindow*) windowhandle;
+
+       return window->endProgressBar();
+}
+
+
 int GHOST_OpenNDOF(GHOST_SystemHandle systemhandle, GHOST_WindowHandle windowhandle,
    GHOST_NDOFLibraryInit_fp setNdofLibraryInit, 
     GHOST_NDOFLibraryShutdown_fp setNdofLibraryShutdown,
@@ -850,15 +865,3 @@ void GHOST_putClipboard(GHOST_TInt8 *buffer, int selection)
        GHOST_ISystem* system = GHOST_ISystem::getSystem();
        system->putClipboard(buffer, selection);
 }
-
-const GHOST_TUns8* GHOST_getSystemDir()
-{
-       GHOST_ISystem* system = GHOST_ISystem::getSystem();
-       return system->getSystemDir();
-}
-
-const GHOST_TUns8* GHOST_getUserDir()
-{
-       GHOST_ISystem* system = GHOST_ISystem::getSystem();
-       return system->getUserDir();
-}
diff --git a/intern/ghost/intern/GHOST_Path-api.cpp b/intern/ghost/intern/GHOST_Path-api.cpp
new file mode 100644 (file)
index 0000000..b2b7c68
--- /dev/null
@@ -0,0 +1,50 @@
+/**
+ * $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 Blender Foundation.
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s): none yet.
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#include "intern/GHOST_Debug.h"
+#include "GHOST_Path-api.h"
+#include "GHOST_ISystem.h"
+
+const GHOST_TUns8* GHOST_getSystemDir()
+{
+       GHOST_ISystem* system = GHOST_ISystem::getSystem();
+       return system ? system->getSystemDir() : NULL;
+}
+
+const GHOST_TUns8* GHOST_getUserDir()
+{
+       GHOST_ISystem* system = GHOST_ISystem::getSystem();
+       return system ? system->getUserDir() : NULL; /* will be NULL in background mode */
+}
+
+const GHOST_TUns8* GHOST_getBinaryDir()
+{
+       GHOST_ISystem* system = GHOST_ISystem::getSystem();
+       return system ? system->getBinaryDir() : NULL; /* will be NULL in background mode */
+}
index d6c6a35..a186707 100644 (file)
@@ -297,7 +297,7 @@ public:
           */
          virtual void putClipboard(GHOST_TInt8 *buffer, bool selection) const = 0;
 
-       /**
+               /**
         * Determine the base dir in which shared resources are located. It will first try to use
         * "unpack and run" path, then look for properly installed path, not including versioning.
         * @return Unsigned char string pointing to system dir (eg /usr/share/blender/).
@@ -311,6 +311,11 @@ public:
         */
        virtual const GHOST_TUns8* getUserDir() const = 0;
 
+       /**
+         * Determine the directory of the current binary
+         * @return Unsigned char string pointing to the binary dir
+         */
+        virtual const GHOST_TUns8* getBinaryDir() const = 0;
 protected:
        /**
         * Initialize the system.
index 5522a07..ecdc03b 100644 (file)
@@ -1215,9 +1215,10 @@ void GHOST_SystemCarbon::putClipboard(GHOST_TInt8 *buffer, bool selection) const
        }
 }
 
+
 const GHOST_TUns8* GHOST_SystemCarbon::getSystemDir() const
 {
-       return (GHOST_TUns8*)"/Library/Application Support/Blender";
+       return (GHOST_TUns8*)"/Library/Application Support";
 }
 
 const GHOST_TUns8* GHOST_SystemCarbon::getUserDir() const
@@ -1228,9 +1229,24 @@ const GHOST_TUns8* GHOST_SystemCarbon::getUserDir() const
        if (env) {
                strncpy(usrPath, env, 245);
                usrPath[245]=0;
-               strcat(usrPath, "/Library/Application Support/Blender");
+               strcat(usrPath, "/Library/Application Support");
                return (GHOST_TUns8*) usrPath;
        }
        else
                return NULL;
 }
+
+const GHOST_TUns8* GHOST_SystemCarbon::getBinaryDir() const
+{
+       CFURLRef bundleURL;
+       CFStringRef pathStr;
+       static char path[256];
+       CFBundleRef mainBundle = CFBundleGetMainBundle();
+       
+       bundleURL = CFBundleCopyBundleURL(mainBundle);
+       pathStr = CFURLCopyFileSystemPath(bundleURL, kCFURLPOSIXPathStyle);
+       CFStringGetCString(pathStr, path, 255, kCFStringEncodingASCII);
+       CFRelease(pathStr);
+       CFRelease(bundleURL);
+       return (GHOST_TUns8*)path;
+}
index ebd9297..723652d 100644 (file)
@@ -190,6 +190,7 @@ public:
         */
        virtual void putClipboard(GHOST_TInt8 *buffer, bool selection) const;
 
+       
        /**
         * Determine the base dir in which shared resources are located. It will first try to use
         * "unpack and run" path, then look for properly installed path, not including versioning.
@@ -204,6 +205,12 @@ public:
         */
        virtual const GHOST_TUns8* getUserDir() const;
 
+       /**
+         * Determine the directory of the current binary
+         * @return Unsigned char string pointing to the binary dir
+         */
+        virtual const GHOST_TUns8* getBinaryDir() const;
+
 protected:
        /**
         * Initializes the system.
index b97c36f..2e7c9b1 100644 (file)
@@ -227,6 +227,12 @@ public:
         */
        virtual const GHOST_TUns8* getUserDir() const;
 
+       /**
+         * Determine the directory of the current binary
+         * @return Unsigned char string pointing to the binary dir
+         */
+        virtual const GHOST_TUns8* getBinaryDir() const;
+
        /**
      * Handles a window event. Called by GHOST_WindowCocoa window delegate
      * @param eventType The type of window event
index 2cec247..6c29b74 100644 (file)
@@ -813,7 +813,11 @@ GHOST_TSuccess GHOST_SystemCocoa::setCursorPosition(GHOST_TInt32 x, GHOST_TInt32
        GHOST_WindowCocoa* window = (GHOST_WindowCocoa*)m_windowManager->getActiveWindow();
        if (!window) return GHOST_kFailure;
 
+       //Cursor and mouse dissociation placed here not to interfere with continuous grab
+       // (in cont. grab setMouseCursorPosition is directly called)
+       CGAssociateMouseAndMouseCursorPosition(false);
        setMouseCursorPosition(x, y);
+       CGAssociateMouseAndMouseCursorPosition(true);
        
        //Force mouse move event (not pushed by Cocoa)
        window->screenToClient(x, y, wx, wy);
@@ -1787,22 +1791,16 @@ const GHOST_TUns8* GHOST_SystemCocoa::getSystemDir() const
 {
        static GHOST_TUns8 tempPath[512] = "";
        NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
-       NSFileManager *fileManager;
        NSString *basePath;
        NSArray *paths;
        
        paths = NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory, NSLocalDomainMask, YES);
        
        if ([paths count] > 0)
-               basePath = [[paths objectAtIndex:0] stringByAppendingPathComponent:@"Blender"];
-       else { //Fall back to standard unix path in case of issue
-               basePath = @"/usr/share/blender";
-       }
-       
-       /* Ensure path exists, creates it if needed */
-       fileManager = [NSFileManager defaultManager];
-       if (![fileManager fileExistsAtPath:basePath isDirectory:NULL]) {
-               [fileManager createDirectoryAtPath:basePath attributes:nil];
+               basePath = [paths objectAtIndex:0];
+       else { 
+               [pool drain];
+               return NULL;
        }
        
        strcpy((char*)tempPath, [basePath cStringUsingEncoding:NSASCIIStringEncoding]);
@@ -1815,22 +1813,35 @@ const GHOST_TUns8* GHOST_SystemCocoa::getUserDir() const
 {
        static GHOST_TUns8 tempPath[512] = "";
        NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
-       NSFileManager *fileManager;
        NSString *basePath;
        NSArray *paths;
 
        paths = NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory, NSUserDomainMask, YES);
 
        if ([paths count] > 0)
-               basePath = [[paths objectAtIndex:0] stringByAppendingPathComponent:@"Blender"];
-       else { //Fall back to HOME in case of issue
-               basePath = [NSHomeDirectory() stringByAppendingPathComponent:@".blender"];
+               basePath = [paths objectAtIndex:0];
+       else { 
+               [pool drain];
+               return NULL;
        }
+
+       strcpy((char*)tempPath, [basePath cStringUsingEncoding:NSASCIIStringEncoding]);
+       
+       [pool drain];
+       return tempPath;
+}
+
+const GHOST_TUns8* GHOST_SystemCocoa::getBinaryDir() const
+{
+       static GHOST_TUns8 tempPath[512] = "";
+       NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+       NSString *basePath;
+       
+       basePath = [[NSBundle mainBundle] bundlePath];
        
-       /* Ensure path exists, creates it if needed */
-       fileManager = [NSFileManager defaultManager];
-       if (![fileManager fileExistsAtPath:basePath isDirectory:NULL]) {
-               [fileManager createDirectoryAtPath:basePath attributes:nil];
+       if (basePath == nil) {
+               [pool drain];
+               return NULL;
        }
        
        strcpy((char*)tempPath, [basePath cStringUsingEncoding:NSASCIIStringEncoding]);
index 76ce770..da7a039 100644 (file)
 #include "GHOST_SystemWin32.h"
 #include "GHOST_EventDragnDrop.h"
 
+#define WIN32_LEAN_AND_MEAN
+#ifdef _WIN32_IE
+#undef _WIN32_IE
+#endif
+#define _WIN32_IE 0x0501
+#include <windows.h>
+#include <shlobj.h>
+
 // win64 doesn't define GWL_USERDATA
 #ifdef WIN32
 #ifndef GWL_USERDATA
@@ -271,6 +279,8 @@ GHOST_TSuccess GHOST_SystemWin32::getCursorPosition(GHOST_TInt32& x, GHOST_TInt3
 
 GHOST_TSuccess GHOST_SystemWin32::setCursorPosition(GHOST_TInt32 x, GHOST_TInt32 y)
 {
+       if (!GetActiveWindow())
+               return GHOST_kFailure;
        return ::SetCursorPos(x, y) == TRUE ? GHOST_kSuccess : GHOST_kFailure;
 }
 
@@ -1093,10 +1103,36 @@ void GHOST_SystemWin32::putClipboard(GHOST_TInt8 *buffer, bool selection) const
 
 const GHOST_TUns8* GHOST_SystemWin32::getSystemDir() const
 {
+       static char knownpath[MAX_PATH];
+       HRESULT hResult = SHGetFolderPath(NULL, CSIDL_COMMON_APPDATA, NULL, SHGFP_TYPE_CURRENT, knownpath);
+
+       if (hResult == S_OK)
+       {
+               return (GHOST_TUns8*)knownpath;
+       }
+
        return NULL;
 }
 
 const GHOST_TUns8* GHOST_SystemWin32::getUserDir() const
 {
+       static char knownpath[MAX_PATH];
+       HRESULT hResult = SHGetFolderPath(NULL, CSIDL_APPDATA, NULL, SHGFP_TYPE_CURRENT, knownpath);
+
+       if (hResult == S_OK)
+       {
+               return (GHOST_TUns8*)knownpath;
+       }
+
+       return NULL;
+}
+
+const GHOST_TUns8* GHOST_SystemWin32::getBinaryDir() const
+{
+       static char fullname[MAX_PATH];
+       if(GetModuleFileName(0, fullname, MAX_PATH)) {
+               return (GHOST_TUns8*)fullname;
+       }
+
        return NULL;
 }
index e65393a..888d9c0 100644 (file)
@@ -186,22 +186,27 @@ public:
         * @return                              No return
         */
        virtual void putClipboard(GHOST_TInt8 *buffer, bool selection) const;
-       
 
        /**
         * Determine the base dir in which shared resources are located. It will first try to use
         * "unpack and run" path, then look for properly installed path, not including versioning.
-        * @return Unsigned char string pointing to system dir (eg /usr/share/blender/).
+        * @return Unsigned char string pointing to system dir (eg /usr/share/).
         */
        virtual const GHOST_TUns8* getSystemDir() const;
 
        /**
         * Determine the base dir in which user configuration is stored, not including versioning.
         * If needed, it will create the base directory.
-        * @return Unsigned char string pointing to user dir (eg ~/.blender/).
+        * @return Unsigned char string pointing to user dir (eg ~/).
         */
         virtual const GHOST_TUns8* getUserDir() const;
 
+        /**
+         * Determine the directory of the current binary
+         * @return Unsigned char string pointing to the binary dir
+         */
+        virtual const GHOST_TUns8* getBinaryDir() const;
+
        /**
         * Creates a drag'n'drop event and pushes it immediately onto the event queue. 
         * Called by GHOST_DropTargetWin32 class.
index 1ae9b66..c9228e6 100644 (file)
@@ -465,7 +465,7 @@ GHOST_SystemX11::processEvent(XEvent *xe)
 
                                /* could also clamp to screen bounds
                                 * wrap with a window outside the view will fail atm  */
-                               bounds.wrapPoint(x_new, y_new, 2); /* offset of one incase blender is at screen bounds */
+                               bounds.wrapPoint(x_new, y_new, 8); /* offset of one incase blender is at screen bounds */
                                window->getCursorGrabAccum(x_accum, y_accum);
 
                                if(x_new != xme.x_root || y_new != xme.y_root) {
@@ -1461,19 +1461,21 @@ void GHOST_SystemX11::putClipboard(GHOST_TInt8 *buffer, bool selection) const
 
 const GHOST_TUns8* GHOST_SystemX11::getSystemDir() const
 {
-       return (GHOST_TUns8*)"/usr/share/blender";
+       return (GHOST_TUns8*)"/usr/share";
 }
 
 const GHOST_TUns8* GHOST_SystemX11::getUserDir() const
 {
-       static char path[256];
        char* env = getenv("HOME");
        if(env) {
-               strncpy(path, env, 245);
-               path[245]=0;
-               strcat(path, "/.blender/");
-               return (GHOST_TUns8*) path;
+               return (GHOST_TUns8*) env;
        } else {
                return NULL;
        }
 }
+
+const GHOST_TUns8* GHOST_SystemX11::getBinaryDir() const
+{
+       return NULL;
+}
+
index ee6cbed..13ad420 100644 (file)
@@ -240,6 +240,12 @@ public:
         */
        const GHOST_TUns8* getUserDir() const;
 
+       /**
+         * Determine the directory of the current binary
+         * @return Unsigned char string pointing to the binary dir
+         */
+        const GHOST_TUns8* getBinaryDir() const;
+
        /**
         * Atom used for ICCCM, WM-spec and Motif.
         * We only need get this atom at the start, it's relative
index e1d0d40..374b620 100644 (file)
@@ -53,6 +53,8 @@ GHOST_Window::GHOST_Window(
        m_isUnsavedChanges = false;
        m_canAcceptDragOperation = false;
        
+       m_progressBarVisible = false;
+       
     m_cursorGrabAccumPos[0] = 0;
     m_cursorGrabAccumPos[1] = 0;
 
index bec9cec..d4d5378 100644 (file)
@@ -191,6 +191,17 @@ public:
         */
        virtual GHOST_TSuccess getCursorGrabBounds(GHOST_Rect& bounds);
 
+       /**
+     * Sets the progress bar value displayed in the window/application icon
+        * @param progress The progress % (0.0 to 1.0)
+        */
+       virtual GHOST_TSuccess setProgressBar(float progress) {return GHOST_kFailure;};
+       
+       /**
+        * Hides the progress bar in the icon
+        */
+       virtual GHOST_TSuccess endProgressBar() {return GHOST_kFailure;};
+       
        /**
         * Tells if the ongoing drag'n'drop object can be accepted upon mouse drop
         */
@@ -313,6 +324,9 @@ protected:
        /** The current shape of the cursor */
        GHOST_TStandardCursor m_cursorShape;
     
+       /** The presence of progress indicator with the application icon */
+       bool m_progressBarVisible;
+       
        /** The acceptance of the "drop candidate" of the current drag'n'drop operation */
        bool m_canAcceptDragOperation;
        
index cb27ee4..7948e88 100644 (file)
@@ -226,6 +226,17 @@ public:
 
        GHOST_TabletData& GetCocoaTabletData()
        { return m_tablet; }
+       
+       /**
+        * Sets the progress bar value displayed in the window/application icon
+        * @param progress The progress % (0.0 to 1.0)
+        */
+       virtual GHOST_TSuccess setProgressBar(float progress);
+       
+       /**
+        * Hides the progress bar icon
+        */
+       virtual GHOST_TSuccess endProgressBar();
 protected:
        /**
         * Tries to install a rendering context in this window.
@@ -291,14 +302,6 @@ protected:
        NSCursor*       m_customCursor;
 
        GHOST_TabletData m_tablet;
-    
-    /**
-     * The width/height of the size rectangle in the lower right corner of a 
-     * Mac/Carbon window. This is also the height of the gutter area.
-     */
-#ifdef GHOST_DRAW_CARBON_GUTTER
-    static const GHOST_TInt32 s_sizeRectSize;
-#endif // GHOST_DRAW_CARBON_GUTTER
 };
 
 #endif // _GHOST_WINDOW_COCOA_H_
index 6dc2fa5..0b22017 100644 (file)
@@ -732,7 +732,7 @@ GHOST_TSuccess GHOST_WindowCocoa::setState(GHOST_TWindowState state)
 #ifdef MAC_OS_X_VERSION_10_6
                                //10.6 provides Cocoa functions to autoshow menu bar, and to change a window style
                                //Hide menu & dock if needed
-                               if ([[m_window screen] isEqual:[NSScreen mainScreen]])
+                               if ([[m_window screen] isEqual:[[NSScreen screens] objectAtIndex:0]])
                                {
                                        [NSApp setPresentationOptions:(NSApplicationPresentationHideDock | NSApplicationPresentationAutoHideMenuBar)];
                                }
@@ -743,7 +743,7 @@ GHOST_TSuccess GHOST_WindowCocoa::setState(GHOST_TWindowState state)
 #else
                                //With 10.5, we need to create a new window to change its style to borderless
                                //Hide menu & dock if needed
-                               if ([[m_window screen] isEqual:[NSScreen mainScreen]])
+                               if ([[m_window screen] isEqual:[[NSScreen screens] objectAtIndex:0]])
                                {
                                        //Cocoa function in 10.5 does not allow to set the menu bar in auto-show mode [NSMenu setMenuBarVisible:NO];
                                        //One of the very few 64bit compatible Carbon function
@@ -1020,6 +1020,66 @@ GHOST_TSuccess GHOST_WindowCocoa::invalidate()
        return GHOST_kSuccess;
 }
 
+#pragma mark Progress bar
+
+GHOST_TSuccess GHOST_WindowCocoa::setProgressBar(float progress)
+{
+       NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+       
+       if ((progress >=0.0) && (progress <=1.0)) {
+               NSImage* dockIcon = [[NSImage alloc] initWithSize:NSMakeSize(128,128)];
+               
+               [dockIcon lockFocus];
+        NSRect progressBox = {{4, 4}, {120, 16}};
+
+        [[NSImage imageNamed:@"NSApplicationIcon"] dissolveToPoint:NSZeroPoint fraction:1.0];
+        
+        // Track & Outline
+        [[NSColor blackColor] setFill];
+        NSRectFill(progressBox);
+        
+        [[NSColor whiteColor] set];
+        NSFrameRect(progressBox);
+        
+        // Progress fill
+        progressBox = NSInsetRect(progressBox, 1, 1);
+        [[NSColor knobColor] setFill];
+        progressBox.size.width = progressBox.size.width * progress;
+               NSRectFill(progressBox);
+               
+               [dockIcon unlockFocus];
+               
+               [NSApp setApplicationIconImage:dockIcon];
+               [dockIcon release];
+               
+               m_progressBarVisible = true;
+       }
+       
+       [pool drain];
+       return GHOST_kSuccess;
+}
+
+
+GHOST_TSuccess GHOST_WindowCocoa::endProgressBar()
+{
+       if (!m_progressBarVisible) return GHOST_kFailure;
+       m_progressBarVisible = false;
+       
+       NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+       
+       NSImage* dockIcon = [[NSImage alloc] initWithSize:NSMakeSize(128,128)];
+       [dockIcon lockFocus];
+       [[NSImage imageNamed:@"NSApplicationIcon"] dissolveToPoint:NSZeroPoint fraction:1.0];
+       [dockIcon unlockFocus];
+       [NSApp setApplicationIconImage:dockIcon];
+       [dockIcon release];
+       
+       [pool drain];
+       return GHOST_kSuccess;
+}
+
+
+
 #pragma mark Cursor handling
 
 void GHOST_WindowCocoa::loadCursor(bool visible, GHOST_TStandardCursor cursor) const
index 1da6485..bbfa84d 100644 (file)
@@ -64,6 +64,7 @@
 LPCSTR GHOST_WindowWin32::s_windowClassName = "GHOST_WindowClass";
 const int GHOST_WindowWin32::s_maxTitleLength = 128;
 HGLRC GHOST_WindowWin32::s_firsthGLRc = NULL;
+HDC GHOST_WindowWin32::s_firstHDC = NULL;
 
 static int WeightPixelFormat(PIXELFORMATDESCRIPTOR& pfd);
 static int EnumPixelFormats(HDC hdc);
@@ -134,6 +135,7 @@ GHOST_WindowWin32::GHOST_WindowWin32(
        m_top(top),
        m_width(width),
        m_height(height),
+       m_normal_state(GHOST_kWindowStateNormal),
        m_stereo(stereoVisual),
        m_nextWindow(NULL)
 {
@@ -202,6 +204,10 @@ GHOST_WindowWin32::GHOST_WindowWin32(
                // Store the device context
                m_hDC = ::GetDC(m_hWnd);
 
+               if(!s_firstHDC) {
+                       s_firstHDC = m_hDC;
+               }
+
                // Show the window
                int nCmdShow;
                switch (state) {
@@ -308,10 +314,11 @@ GHOST_WindowWin32::~GHOST_WindowWin32()
                m_customCursor = NULL;
        }
 
+       ::wglMakeCurrent(NULL, NULL);
        m_multisampleEnabled = GHOST_kFailure;
        m_multisample = 0;
        setDrawingContextType(GHOST_kDrawingContextTypeNone);
-       if (m_hDC) {
+       if (m_hDC && m_hDC != s_firstHDC) {
                ::ReleaseDC(m_hWnd, m_hDC);
                m_hDC = 0;
        }
@@ -482,9 +489,13 @@ void GHOST_WindowWin32::clientToScreen(GHOST_TInt32 inX, GHOST_TInt32 inY, GHOST
 
 GHOST_TSuccess GHOST_WindowWin32::setState(GHOST_TWindowState state)
 {
+       GHOST_TWindowState curstate = getState();
        WINDOWPLACEMENT wp;
        wp.length = sizeof(WINDOWPLACEMENT);
        ::GetWindowPlacement(m_hWnd, &wp);
+
+       if (state == GHOST_kWindowStateNormal)
+               state = m_normal_state;
        switch (state) {
        case GHOST_kWindowStateMinimized:
                wp.showCmd = SW_SHOWMINIMIZED;
@@ -495,6 +506,8 @@ GHOST_TSuccess GHOST_WindowWin32::setState(GHOST_TWindowState state)
                SetWindowLongPtr(m_hWnd, GWL_STYLE, WS_OVERLAPPEDWINDOW);
                break;
        case GHOST_kWindowStateFullScreen:
+               if (curstate != state && curstate != GHOST_kWindowStateMinimized)
+                       m_normal_state = curstate;
                wp.showCmd = SW_SHOWMAXIMIZED;
                wp.ptMaxPosition.x = 0;
                wp.ptMaxPosition.y = 0;
@@ -637,6 +650,7 @@ GHOST_TSuccess GHOST_WindowWin32::installDrawingContext(GHOST_TDrawingContextTyp
                        m_hGlRc = ::wglCreateContext(m_hDC);
                        if (m_hGlRc) {
                                if (s_firsthGLRc) {
+                                       ::wglCopyContext(s_firsthGLRc, m_hGlRc, GL_ALL_ATTRIB_BITS);
                                        wglShareLists(s_firsthGLRc, m_hGlRc);
                                } else {
                                        s_firsthGLRc = m_hGlRc;
index 5e1f708..a4d31f8 100644 (file)
@@ -315,6 +315,8 @@ protected:
        HGLRC m_hGlRc;
        /** The first created OpenGL context (for sharing display lists) */
        static HGLRC s_firsthGLRc;
+       /** The first created device context handle. */
+       static HDC s_firstHDC;
        /** Flag for if window has captured the mouse */
        bool m_hasMouseCaptured;
        /** Count of number of pressed buttons */
@@ -351,6 +353,7 @@ protected:
        GHOST_TInt32 m_top;
        GHOST_TUns32 m_width;
        GHOST_TUns32 m_height;
+       GHOST_TWindowState m_normal_state;
        bool m_stereo;
 
        /** The GHOST_System passes this to wm if this window is being replaced */
index 9be2787..60e12ff 100644 (file)
@@ -57,6 +57,9 @@ typedef struct {
 
 #define MWM_HINTS_DECORATIONS         (1L << 1)
 
+
+// #define GHOST_X11_GRAB
+
 /*
  * A Client can't change the window property, that is
  * the work of the window manager. In case, we send
@@ -159,6 +162,7 @@ GHOST_WindowX11(
        GHOST_Window(title,left,top,width,height,state,type,stereoVisual,numOfAASamples),
        m_context(NULL),
        m_display(display),
+       m_normal_state(GHOST_kWindowStateNormal),
        m_system (system),
        m_valid_setup (false),
        m_invalid_window(false),
@@ -1036,6 +1040,9 @@ GHOST_TSuccess GHOST_WindowX11::setState(GHOST_TWindowState state)
 
        is_motif_full = motifIsFullScreen();
 
+       if (state == GHOST_kWindowStateNormal)
+               state = m_normal_state;
+
        if (state == GHOST_kWindowStateNormal) {
                if (is_max == True)
                        netwmMaximized(False);
@@ -1055,6 +1062,8 @@ GHOST_TSuccess GHOST_WindowX11::setState(GHOST_TWindowState state)
                if (cur_state == GHOST_kWindowStateMinimized)
                        return (GHOST_kFailure);
 
+               m_normal_state = cur_state;
+
                if (is_max == True)
                        netwmMaximized(False);
                if (is_full == False)
@@ -1436,7 +1445,9 @@ setWindowCursorGrab(
                                setWindowCursorVisibility(false);
 
                }
+#ifdef GHOST_X11_GRAB
                XGrabPointer(m_display, m_window, False, ButtonPressMask| ButtonReleaseMask|PointerMotionMask, GrabModeAsync, GrabModeAsync, None, None, CurrentTime);
+#endif
        }
        else {
                if (m_cursorGrab==GHOST_kGrabHide) {
@@ -1454,7 +1465,9 @@ setWindowCursorGrab(
                /* Almost works without but important otherwise the mouse GHOST location can be incorrect on exit */
                setCursorGrabAccum(0, 0);
                m_cursorGrabBounds.m_l= m_cursorGrabBounds.m_r= -1; /* disable */
+#ifdef GHOST_X11_GRAB
              &nb