Commit Graph

345 Commits

Author SHA1 Message Date
Campbell Barton
711d7539e0 style cleanup: for creator.c & more useful assert message (file:line) 2012-03-28 05:09:50 +00:00
Campbell Barton
b8a71efeba style cleanup: follow style guide for/with/if spacing 2012-03-24 07:52:14 +00:00
Campbell Barton
ab4a2aaf4a style cleanup: follow style guide for formatting of if/for/while loops, and else if's 2012-03-24 06:38:07 +00:00
Alexander Kuznetsov
f11a6d3a84 Adds support for utf paths on Windows.
Not all file formats/calls are supported yet. It will be expended.

Please from now on use BLI_fopen, BLI_* for file manipulations.
For non-windows systems BLI_fopen just calls fopen.
For Windows, the utf-8 string is translated to utf-16 string in order to call UTF version of the function.
2012-03-20 02:17:37 +00:00
Campbell Barton
4f19c1a995 spelling cleanup 2012-03-18 07:38:51 +00:00
Campbell Barton
0c50bedd9c code cleanup: remove unused externs. 2012-03-11 00:00:27 +00:00
Campbell Barton
89a963fb7f style cleanup: comment blocks 2012-03-09 18:28:30 +00:00
Campbell Barton
79d97ca509 style cleanup - spelling. 2012-03-08 04:12:11 +00:00
Campbell Barton
46045fbb09 style cleanup - braces & else / if's 2012-03-07 04:53:43 +00:00
Campbell Barton
31d2ee9bf7 style cleanup, brackets in else/if, some indentation. 2012-03-06 18:40:15 +00:00
Campbell Barton
9d49fa0e63 style cleanup - spelling corrections & update some incorrect comments. 2012-03-03 11:45:08 +00:00
Campbell Barton
02b28e9162 replace MIN2 / MAX2 with minf / maxf to avoid calling functions multiple times. 2012-02-19 05:11:24 +00:00
Brecht Van Lommel
3b12a4b92b Fix for standalone bpy module building link errors on Mac.
It seems to be working now, however make sure to build against the exact same
python version as the one you will use it with, the version in the lib/darwin*
directory is likely to differ from python installed on your system.
2012-01-16 14:13:41 +00:00
Campbell Barton
7f555daa64 print message for unknown args to make it clear that these are not recognized. 2012-01-05 11:02:27 +00:00
Campbell Barton
986e62f3b6 fix for a bug in mathutils when a vector was accessing a matrix and the matrix size increased, future access too the vector would write past the allocated bounds. now raise an exception. 2011-12-26 00:05:41 +00:00
Campbell Barton
6736576f6d replace FILE_MAXDIR + FILE_MAXFILE with FILE_MAX 2011-11-26 04:07:38 +00:00
Campbell Barton
df22957bfc image format arg parsing for creator.c
move these checks from creator into BKE's image.c, this way we dont need the defines for creator, scons was missing DDS, HDR & Cineon  for example and nobody noticed.
2011-11-24 05:18:26 +00:00
Campbell Barton
743d2f8c0f rename image type defines to be less ambiguous, also set BMP as not supporting alpha (it reads but cant write) 2011-11-22 00:35:26 +00:00
Campbell Barton
30fd1ab523 replace ImBuf.depth with ImBuf.planes to match ImageFormatData.planes & to avoid confusion with ImageFormatData.depth 2011-11-21 20:47:19 +00:00
Campbell Barton
0e2c8cdcdd move image settings into their own structure so the interface can be shared where image saving settings are needed.
currently file out node and render output share this struct & UI.
2011-11-21 20:19:58 +00:00
Brecht Van Lommel
0792ab3652 Fix #29232: on background render where it could not find the .blend file, the
default cube would be rendered instead, now stops processing arguments after
failed file load.
2011-11-15 23:03:35 +00:00
Sergey Sharybin
27d42c63d9 Camera tracking integration
===========================

Commiting camera tracking integration gsoc project into trunk.

This commit includes:

- Bundled version of libmv library (with some changes against official repo,
  re-sync with libmv repo a bit later)
- New datatype ID called MovieClip which is optimized to work with movie
  clips (both of movie files and image sequences) and doing camera/motion
  tracking operations.
- New editor called Clip Editor which is currently used for motion/tracking
  stuff only, but which can be easily extended to work with masks too.

  This editor supports:
  * Loading movie files/image sequences
  * Build proxies with different size for loaded movie clip, also supports
    building undistorted proxies to increase speed of playback in
    undistorted mode.
  * Manual lens distortion mode calibration using grid and grease pencil
  * Supervised 2D tracking using two different algorithms KLT and SAD.
  * Basic algorithm for feature detection
  * Camera motion solving. scene orientation

- New constraints to "link" scene objects with solved motions from clip:

  * Follow Track (make object follow 2D motion of track with given name
    or parent object to reconstructed 3D position of track)
  * Camera Solver to make camera moving in the same way as reconstructed camera

This commit NOT includes changes from tomato branch:

- New nodes (they'll be commited as separated patch)
- Automatic image offset guessing for image input node and image editor
  (need to do more tests and gather more feedback)
- Code cleanup in libmv-capi. It's not so critical cleanup, just increasing
  readability and understanadability of code. Better to make this chaneg when
  Keir will finish his current patch.

More details about this project can be found on this page:
    http://wiki.blender.org/index.php/User:Nazg-gul/GSoC-2011

Further development of small features would be done in trunk, bigger/experimental
features would first be implemented in tomato branch.
2011-11-07 12:55:18 +00:00
Campbell Barton
62f2218554 macro formatting & remve some unused code. 2011-11-05 05:44:52 +00:00
Campbell Barton
e2393d1109 ability to have permanent callbacks that stay active when new blend files are loaded.
this works by tagging functions, eg:

  def my_func(scene):
      pass

  bpy.app.handlers.permanent_tag(my_func, True)  # <-- important bit
  bpy.app.handlers.frame_change_pre.append(my_func)
2011-11-03 06:53:52 +00:00
Campbell Barton
4a04f72069 remove $Id: tags after discussion on the mailign list: http://markmail.org/message/fp7ozcywxum3ar7n 2011-10-23 17:52:20 +00:00
Brecht Van Lommel
1bdf652b89 Code refactoring: move external engine functions into own file. 2011-10-22 16:24:28 +00:00
Brecht Van Lommel
00735ed9e4 Code cleanup: don't use btempdir/bprogdir/bprogname globals anymore, but wrap
in BLI_ functions.
2011-10-21 17:37:38 +00:00
Campbell Barton
ef218c75ed - add convenience functions BLI_split_dir_part / BLI_split_file_part, which just call BLI_split_dirfile().
- add a fixed value for bprogdir (the dir of bprogname), since it was being used for resource lookups.
2011-10-21 02:13:36 +00:00
Campbell Barton
4512f10db9 misc edits
- rename define DISABLE_SDL --> WITH_SDL (which was already used in some places)
- blenders interation preset was using orbit rather then turntable 3d view preference (different from factory defaults).
- tagged some unused rna args.
2011-10-20 00:19:21 +00:00
Campbell Barton
58587a3881 replace strncpy with BLI_strncpy, in some cases strncpy was being misused since it doesnt ensure \0 termination.
also dont call CTX_data_scene() twice when checking for function arguments.
2011-09-26 18:51:10 +00:00
Campbell Barton
274b9c8fb8 whitespace cleanup 2011-09-25 12:31:21 +00:00
Campbell Barton
4b449aefea remove support for irix 2011-09-21 08:40:30 +00:00
Campbell Barton
0d355a8a2c replace BLI_strncpy with BLI_strncpy_utf8 where input isnt ensured to be valid.
also replace strcpy's which copy using "" with str[0]='\0'
2011-09-15 12:26:48 +00:00
Campbell Barton
3d3f6b1ddc fix for 'blender -E' crashing. 2011-09-11 13:46:58 +00:00
Campbell Barton
7d316b70b8 rename NAN_BUILDINFO --> WITH_BUILDINFO 2011-08-22 16:54:26 +00:00
Campbell Barton
817273931a buildinfo is now quoted from the build systems, avoids stripping quotes on startup.
tested with linux/cmake linux/scons windows/cmake/mingw windows/cmake/msvc
2011-08-22 12:24:14 +00:00
Campbell Barton
2658949752 pep8 cleanup, also print message when attempting to run in animation player mode. 2011-07-29 01:24:03 +00:00
Campbell Barton
80eb1eae42 run WM_exit(C) when blender as a python module exits 2011-07-10 18:54:02 +00:00
Brecht Van Lommel
8ddd2db648 RenderEngine API: add self.report() error reporting function for render engines,
works the same as for operators. Also includes some refactoring of render error
reporting code to use ReportList.
2011-06-28 16:25:07 +00:00
Campbell Barton
12e02fd474 own patch [#27752] Python Callback (Scriptlink functionality)
Python:
 * adds bpy.app.handlers which contains lists, each for an event type:
   render_pre, render_post, load_pre, load_post, save_pre, save_post
 * each list item needs to be a callable object which takes 1 argument (the ID).
 * callbacks are cleared on file load.

Example:
 def MyFunc(scene): print("Callback:", data)
 bpy.app.handlers.render_post.append(MyFunc)

C:
 * This patch adds a generic C callback api which is currently only used by python.
 * Unlike python callbacks these are not cleared on file load.
2011-06-24 16:54:30 +00:00
Campbell Barton
eeba877926 fix [#27607] Scene's render.filepath gets cropped to 159 characters
use 240 char limit, remove backbuffer path which wasn't used.
2011-06-10 10:13:50 +00:00
Campbell Barton
4a59928484 CMake option 'WITH_HEADLESS' to build blender in headless mode (no x11/xlib) with NULL ghost classe. 2011-06-04 14:12:55 +00:00
M.G. Kishalmi
9b5800bcd7 fixed "rather then" -> "rather than" typos all over the place 2011-05-28 13:11:24 +00:00
Brecht Van Lommel
d369a6aaaf Windows installer and Path changes, fixing various issues:
* Windows installer not working for non-admin users and multiple users
* Addon scripts not installing next to user configuration
* Portable install not being taken into account in all places

The main problem was the windows installer was installing system scripts in
AppData next to the user configuration directory, which is not shared between
users. Now these are installed in ProgramFiles, and only addon scripts added
by the users go to AppData.

On all platforms, addon scripts were sometimes getting installed between
system scripts, because the scripts folder in the executable directory was
given precedence over the user configuration folder, that is no longer done
now. So addons now behave like user configuration, they are preserved even
if you download a newer build of the same blender version.

If you have an installation of 2.57 on windows, the addon install location
will not change until we do the version bump to 2.58, to avoid conflicts with
the existing the installed 2.57 version.

The old behavior of giving precedence to the local folder was done to support
portable install, where all configuration is written to the local folder. This
is now implemented differently: if and only if a "config" folder exists in the
local folder, portable install will be assumed, and files will only be written
to that local folder.
2011-05-27 09:57:53 +00:00
Campbell Barton
6e39d908a9 quiet compiler warnings for -Wundef 2011-05-22 04:25:31 +00:00
Campbell Barton
80c2582f0e enable game panel even if the BGE is disabled since its settings effect the viewport.
also remove unused function in creator.c and minor edit to search menu poll function.
2011-05-16 04:55:31 +00:00
Brecht Van Lommel
cb12337363 Code cleanup: remove source/kernel module, this wasn't really the kernel of
anything, only contained a hash map and functions to pass command line args
to the game engine. Moved those to container and BlenderRoutines modules.
2011-05-06 20:18:42 +00:00
Campbell Barton
abcdf9573a add back support for rendering local view camera. 2011-04-30 04:29:36 +00:00
Campbell Barton
11305bd688 CMake build option for security report: CVE-2009-3850
Nothing is changed by default but some linux distributions want to have executing python be opt-in.

This keeps the same functionality but disables auto-run from factory settings and in background mode unless its enabled as a command line argument.

This CMake option is marked as advanced and wont show in the regular options list so its less likely to be enabled by people that like to turn everything ON without reading descriptions :)
2011-04-28 06:20:47 +00:00
Campbell Barton
f9f771cd01 converted more mixed tab/space indentations to tabs. only whitespace changes. 2011-04-21 15:53:30 +00:00