2012-12-17 08:01:43 +00:00
|
|
|
#!/usr/bin/env 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.
|
|
|
|
#
|
|
|
|
# The Original Code is Copyright (C) 2006, Blender Foundation
|
|
|
|
# All rights reserved.
|
|
|
|
#
|
|
|
|
# The Original Code is: all of this file.
|
|
|
|
#
|
|
|
|
# Contributor(s): Nathan Letwory.
|
|
|
|
#
|
|
|
|
# ***** END GPL LICENSE BLOCK *****
|
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
Import ('env')
|
2011-09-11 15:17:54 +00:00
|
|
|
import os
|
2004-02-29 21:40:48 +00:00
|
|
|
|
2011-09-20 16:24:50 +00:00
|
|
|
sources = env.Glob('intern/*.c')
|
Color Management, Stage 2: Switch color pipeline to use OpenColorIO
Replace old color pipeline which was supporting linear/sRGB color spaces
only with OpenColorIO-based pipeline.
This introduces two configurable color spaces:
- Input color space for images and movie clips. This space is used to convert
images/movies from color space in which file is saved to Blender's linear
space (for float images, byte images are not internally converted, only input
space is stored for such images and used later).
This setting could be found in image/clip data block settings.
- Display color space which defines space in which particular display is working.
This settings could be found in scene's Color Management panel.
When render result is being displayed on the screen, apart from converting image
to display space, some additional conversions could happen.
This conversions are:
- View, which defines tone curve applying before display transformation.
These are different ways to view the image on the same display device.
For example it could be used to emulate film view on sRGB display.
- Exposure affects on image exposure before tone map is applied.
- Gamma is post-display gamma correction, could be used to match particular
display gamma.
- RGB curves are user-defined curves which are applying before display
transformation, could be used for different purposes.
All this settings by default are only applying on render result and does not
affect on other images. If some particular image needs to be affected by this
transformation, "View as Render" setting of image data block should be set to
truth. Movie clips are always affected by all display transformations.
This commit also introduces configurable color space in which sequencer is
working. This setting could be found in scene's Color Management panel and
it should be used if such stuff as grading needs to be done in color space
different from sRGB (i.e. when Film view on sRGB display is use, using VD16
space as sequencer's internal space would make grading working in space
which is close to the space using for display).
Some technical notes:
- Image buffer's float buffer is now always in linear space, even if it was
created from 16bit byte images.
- Space of byte buffer is stored in image buffer's rect_colorspace property.
- Profile of image buffer was removed since it's not longer meaningful.
- OpenGL and GLSL is supposed to always work in sRGB space. It is possible
to support other spaces, but it's quite large project which isn't so
much important.
- Legacy Color Management option disabled is emulated by using None display.
It could have some regressions, but there's no clear way to avoid them.
- If OpenColorIO is disabled on build time, it should make blender behaving
in the same way as previous release with color management enabled.
More details could be found at this page (more details would be added soon):
http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.64/Color_Management
--
Thanks to Xavier Thomas, Lukas Toene for initial work on OpenColorIO
integration and to Brecht van Lommel for some further development and code/
usecase review!
2012-09-15 10:05:07 +00:00
|
|
|
sources.remove('intern' + os.sep + 'mask_rasterize.c')
|
2012-11-13 19:17:35 +00:00
|
|
|
sources.remove('intern' + os.sep + 'mask_evaluate.c')
|
Color Management, Stage 2: Switch color pipeline to use OpenColorIO
Replace old color pipeline which was supporting linear/sRGB color spaces
only with OpenColorIO-based pipeline.
This introduces two configurable color spaces:
- Input color space for images and movie clips. This space is used to convert
images/movies from color space in which file is saved to Blender's linear
space (for float images, byte images are not internally converted, only input
space is stored for such images and used later).
This setting could be found in image/clip data block settings.
- Display color space which defines space in which particular display is working.
This settings could be found in scene's Color Management panel.
When render result is being displayed on the screen, apart from converting image
to display space, some additional conversions could happen.
This conversions are:
- View, which defines tone curve applying before display transformation.
These are different ways to view the image on the same display device.
For example it could be used to emulate film view on sRGB display.
- Exposure affects on image exposure before tone map is applied.
- Gamma is post-display gamma correction, could be used to match particular
display gamma.
- RGB curves are user-defined curves which are applying before display
transformation, could be used for different purposes.
All this settings by default are only applying on render result and does not
affect on other images. If some particular image needs to be affected by this
transformation, "View as Render" setting of image data block should be set to
truth. Movie clips are always affected by all display transformations.
This commit also introduces configurable color space in which sequencer is
working. This setting could be found in scene's Color Management panel and
it should be used if such stuff as grading needs to be done in color space
different from sRGB (i.e. when Film view on sRGB display is use, using VD16
space as sequencer's internal space would make grading working in space
which is close to the space using for display).
Some technical notes:
- Image buffer's float buffer is now always in linear space, even if it was
created from 16bit byte images.
- Space of byte buffer is stored in image buffer's rect_colorspace property.
- Profile of image buffer was removed since it's not longer meaningful.
- OpenGL and GLSL is supposed to always work in sRGB space. It is possible
to support other spaces, but it's quite large project which isn't so
much important.
- Legacy Color Management option disabled is emulated by using None display.
It could have some regressions, but there's no clear way to avoid them.
- If OpenColorIO is disabled on build time, it should make blender behaving
in the same way as previous release with color management enabled.
More details could be found at this page (more details would be added soon):
http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.64/Color_Management
--
Thanks to Xavier Thomas, Lukas Toene for initial work on OpenColorIO
integration and to Brecht van Lommel for some further development and code/
usecase review!
2012-09-15 10:05:07 +00:00
|
|
|
sources.remove('intern' + os.sep + 'mask.c')
|
|
|
|
|
|
|
|
sources_mask = env.Glob('intern/mask*.c')
|
2004-01-04 21:11:59 +00:00
|
|
|
|
2011-09-14 00:37:27 +00:00
|
|
|
incs = '. #/intern/guardedalloc #/intern/memutil'
|
2009-12-13 19:45:23 +00:00
|
|
|
incs += ' ../blenlib ../blenfont ../makesdna ../windowmanager'
|
2012-10-22 02:39:26 +00:00
|
|
|
incs += ' ../render/extern/include ../makesrna'
|
2010-04-11 22:12:30 +00:00
|
|
|
incs += ' ../imbuf ../ikplugin ../avi #/intern/elbeem/extern ../nodes ../modifiers'
|
2008-11-11 14:14:22 +00:00
|
|
|
incs += ' #/intern/iksolver/extern ../blenloader'
|
2008-01-29 21:01:12 +00:00
|
|
|
incs += ' #/extern/bullet2/src'
|
2009-01-07 17:25:17 +00:00
|
|
|
incs += ' #/intern/opennl/extern #/intern/bsp/extern'
|
Merge of first part of changes from the apricot branch, especially
the features that are needed to run the game. Compile tested with
scons, make, but not cmake, that seems to have an issue not related
to these changes. The changes include:
* GLSL support in the viewport and game engine, enable in the game
menu in textured draw mode.
* Synced and merged part of the duplicated blender and gameengine/
gameplayer drawing code.
* Further refactoring of game engine drawing code, especially mesh
storage changed a lot.
* Optimizations in game engine armatures to avoid recomputations.
* A python function to get the framerate estimate in game.
* An option take object color into account in materials.
* An option to restrict shadow casters to a lamp's layers.
* Increase from 10 to 18 texture slots for materials, lamps, word.
An extra texture slot shows up once the last slot is used.
* Memory limit for undo, not enabled by default yet because it
needs the .B.blend to be changed.
* Multiple undo for image painting.
* An offset for dupligroups, so not all objects in a group have to
be at the origin.
2008-09-04 20:51:28 +00:00
|
|
|
incs += ' ../gpu #/extern/glew/include'
|
2009-05-16 16:18:08 +00:00
|
|
|
incs += ' ../bmesh'
|
2009-07-30 15:00:26 +00:00
|
|
|
incs += ' #/intern/smoke/extern'
|
2011-02-15 09:24:35 +00:00
|
|
|
incs += ' #/intern/mikktspace'
|
2009-08-10 19:22:50 +00:00
|
|
|
incs += ' #/intern/audaspace/intern'
|
2011-05-27 23:33:40 +00:00
|
|
|
incs += ' #/intern/ffmpeg'
|
2012-06-04 16:42:58 +00:00
|
|
|
incs += ' #/intern/raskter'
|
2004-01-04 21:11:59 +00:00
|
|
|
|
2006-02-04 14:15:10 +00:00
|
|
|
incs += ' ' + env['BF_OPENGL_INC']
|
|
|
|
incs += ' ' + env['BF_ZLIB_INC']
|
2004-01-04 21:11:59 +00:00
|
|
|
|
2009-11-21 20:36:03 +00:00
|
|
|
defs = [ 'GLEW_STATIC' ]
|
2004-02-23 14:39:08 +00:00
|
|
|
|
2012-04-14 21:55:38 +00:00
|
|
|
if env['WITH_BF_SMOKE']:
|
|
|
|
defs.append('WITH_SMOKE')
|
|
|
|
|
2012-04-14 22:19:29 +00:00
|
|
|
if env['WITH_BF_FRAMESERVER']:
|
|
|
|
defs.append('WITH_FRAMESERVER')
|
2011-07-13 18:40:21 +00:00
|
|
|
|
2010-10-31 04:11:39 +00:00
|
|
|
if env['WITH_BF_PYTHON']:
|
2010-08-29 20:52:05 +00:00
|
|
|
incs += ' ../python'
|
2010-10-31 04:11:39 +00:00
|
|
|
defs.append('WITH_PYTHON')
|
2010-08-29 20:52:05 +00:00
|
|
|
if env['BF_DEBUG']:
|
2010-10-18 07:24:08 +00:00
|
|
|
defs.append('DEBUG')
|
2008-10-28 18:47:13 +00:00
|
|
|
|
2012-11-27 09:52:20 +00:00
|
|
|
'''
|
2011-05-01 21:39:13 +00:00
|
|
|
if env['WITH_BF_ELTOPO']:
|
2012-08-12 18:01:27 +00:00
|
|
|
incs += ' #/extern/eltopo'
|
|
|
|
incs += ' #/extern/eltopo/eltopo3d'
|
2011-05-02 03:44:02 +00:00
|
|
|
defs.append('WITH_ELTOPO')
|
2012-11-27 09:52:20 +00:00
|
|
|
'''
|
2008-11-11 14:14:22 +00:00
|
|
|
if env['WITH_BF_QUICKTIME']:
|
2010-08-29 20:52:05 +00:00
|
|
|
incs += ' ../quicktime'
|
2008-11-11 14:14:22 +00:00
|
|
|
|
|
|
|
if env['WITH_BF_SDL']:
|
2010-08-29 20:52:05 +00:00
|
|
|
incs += ' ' + env['BF_SDL_INC']
|
2011-10-20 00:19:21 +00:00
|
|
|
defs.append('WITH_SDL')
|
2008-11-11 14:14:22 +00:00
|
|
|
|
2008-10-22 11:28:10 +00:00
|
|
|
if env['WITH_BF_OPENEXR']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_OPENEXR')
|
2004-06-04 12:58:46 +00:00
|
|
|
|
2010-05-21 03:25:38 +00:00
|
|
|
if env['WITH_BF_TIFF']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_TIFF')
|
2010-05-21 03:25:38 +00:00
|
|
|
|
2009-01-26 08:34:40 +00:00
|
|
|
if env['WITH_BF_OPENJPEG']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_OPENJPEG')
|
2009-01-26 08:34:40 +00:00
|
|
|
|
2008-10-22 11:28:10 +00:00
|
|
|
if env['WITH_BF_DDS']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_DDS')
|
2007-06-25 19:50:25 +00:00
|
|
|
|
2010-08-03 11:25:34 +00:00
|
|
|
if env['WITH_BF_CINEON']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_CINEON')
|
2010-08-03 11:25:34 +00:00
|
|
|
|
|
|
|
if env['WITH_BF_HDR']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_HDR')
|
2010-08-03 11:25:34 +00:00
|
|
|
|
2010-10-02 15:27:55 +00:00
|
|
|
if env['WITH_BF_JACK']:
|
|
|
|
defs.append('WITH_JACK')
|
2010-08-03 11:25:34 +00:00
|
|
|
|
2008-10-22 11:28:10 +00:00
|
|
|
if env['WITH_BF_FFMPEG']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_FFMPEG')
|
|
|
|
incs += ' ' + env['BF_FFMPEG_INC']
|
2006-02-05 19:12:25 +00:00
|
|
|
|
2008-10-22 11:28:10 +00:00
|
|
|
if env['WITH_BF_QUICKTIME']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('WITH_QUICKTIME')
|
|
|
|
incs += ' ' + env['BF_QUICKTIME_INC']
|
2005-04-05 15:02:21 +00:00
|
|
|
|
2009-01-26 08:34:40 +00:00
|
|
|
if env['WITH_BF_BULLET']:
|
2010-08-29 20:52:05 +00:00
|
|
|
defs.append('USE_BULLET')
|
2009-01-26 08:34:40 +00:00
|
|
|
|
2010-02-07 14:25:09 +00:00
|
|
|
if env['OURPLATFORM'] == 'darwin':
|
|
|
|
if env['WITH_BF_OPENMP']:
|
|
|
|
defs.append('PARALLEL=1')
|
|
|
|
|
2011-10-29 23:56:07 +00:00
|
|
|
if env['WITH_BF_FLUID']:
|
|
|
|
defs.append('WITH_MOD_FLUID')
|
2006-02-04 14:15:10 +00:00
|
|
|
|
2011-11-13 12:17:27 +00:00
|
|
|
if env['WITH_BF_OCEANSIM']:
|
|
|
|
defs.append('WITH_OCEANSIM')
|
|
|
|
|
2009-10-22 23:22:05 +00:00
|
|
|
if env['WITH_BF_LZO']:
|
2010-08-29 20:52:05 +00:00
|
|
|
incs += ' #/extern/lzo/minilzo'
|
|
|
|
defs.append('WITH_LZO')
|
2009-10-22 23:22:05 +00:00
|
|
|
|
|
|
|
if env['WITH_BF_LZMA']:
|
2010-08-29 20:52:05 +00:00
|
|
|
incs += ' #/extern/lzma'
|
|
|
|
defs.append('WITH_LZMA')
|
2009-10-22 23:22:05 +00:00
|
|
|
|
2011-09-11 14:13:04 +00:00
|
|
|
if env['WITH_BF_GAMEENGINE']:
|
2011-09-20 16:24:50 +00:00
|
|
|
incs += ' #/extern/recastnavigation'
|
2011-09-11 14:13:04 +00:00
|
|
|
defs.append('WITH_GAMEENGINE')
|
|
|
|
else:
|
2011-09-20 16:24:50 +00:00
|
|
|
sources.remove('intern' + os.sep + 'navmesh_conversion.c')
|
2011-09-11 14:13:04 +00:00
|
|
|
|
2011-11-07 12:55:18 +00:00
|
|
|
if env['WITH_BF_LIBMV']:
|
|
|
|
incs += ' #/extern/libmv'
|
|
|
|
defs.append('WITH_LIBMV')
|
|
|
|
|
2011-11-13 12:17:27 +00:00
|
|
|
if env['WITH_BF_FFTW3']:
|
|
|
|
defs.append('FFTW3=1')
|
|
|
|
incs += ' ' + env['BF_FFTW3_INC']
|
|
|
|
|
2012-03-17 12:07:58 +00:00
|
|
|
if env['WITH_BF_INTERNATIONAL']:
|
|
|
|
defs.append('WITH_INTERNATIONAL')
|
|
|
|
|
2012-04-24 12:57:58 +00:00
|
|
|
if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'linuxcross', 'win64-vc', 'win64-mingw'):
|
2009-01-12 19:14:33 +00:00
|
|
|
incs += ' ' + env['BF_PTHREADS_INC']
|
|
|
|
|
Color Management, Stage 2: Switch color pipeline to use OpenColorIO
Replace old color pipeline which was supporting linear/sRGB color spaces
only with OpenColorIO-based pipeline.
This introduces two configurable color spaces:
- Input color space for images and movie clips. This space is used to convert
images/movies from color space in which file is saved to Blender's linear
space (for float images, byte images are not internally converted, only input
space is stored for such images and used later).
This setting could be found in image/clip data block settings.
- Display color space which defines space in which particular display is working.
This settings could be found in scene's Color Management panel.
When render result is being displayed on the screen, apart from converting image
to display space, some additional conversions could happen.
This conversions are:
- View, which defines tone curve applying before display transformation.
These are different ways to view the image on the same display device.
For example it could be used to emulate film view on sRGB display.
- Exposure affects on image exposure before tone map is applied.
- Gamma is post-display gamma correction, could be used to match particular
display gamma.
- RGB curves are user-defined curves which are applying before display
transformation, could be used for different purposes.
All this settings by default are only applying on render result and does not
affect on other images. If some particular image needs to be affected by this
transformation, "View as Render" setting of image data block should be set to
truth. Movie clips are always affected by all display transformations.
This commit also introduces configurable color space in which sequencer is
working. This setting could be found in scene's Color Management panel and
it should be used if such stuff as grading needs to be done in color space
different from sRGB (i.e. when Film view on sRGB display is use, using VD16
space as sequencer's internal space would make grading working in space
which is close to the space using for display).
Some technical notes:
- Image buffer's float buffer is now always in linear space, even if it was
created from 16bit byte images.
- Space of byte buffer is stored in image buffer's rect_colorspace property.
- Profile of image buffer was removed since it's not longer meaningful.
- OpenGL and GLSL is supposed to always work in sRGB space. It is possible
to support other spaces, but it's quite large project which isn't so
much important.
- Legacy Color Management option disabled is emulated by using None display.
It could have some regressions, but there's no clear way to avoid them.
- If OpenColorIO is disabled on build time, it should make blender behaving
in the same way as previous release with color management enabled.
More details could be found at this page (more details would be added soon):
http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.64/Color_Management
--
Thanks to Xavier Thomas, Lukas Toene for initial work on OpenColorIO
integration and to Brecht van Lommel for some further development and code/
usecase review!
2012-09-15 10:05:07 +00:00
|
|
|
|
2010-10-21 07:39:18 +00:00
|
|
|
if env['OURPLATFORM'] in ('win32-vc', 'win64-vc'):
|
2010-10-26 23:32:59 +00:00
|
|
|
env.BlenderLib ( libname = 'bf_blenkernel', sources = sources, includes = Split(incs), defines = defs, libtype=['core','player'], priority = [166,25]) #, cc_compileflags = env['CCFLAGS'].append('/WX') )
|
2010-10-21 07:39:18 +00:00
|
|
|
else:
|
2010-12-21 00:21:42 +00:00
|
|
|
env.BlenderLib ( libname = 'bf_blenkernel', sources = sources, includes = Split(incs), defines = defs, libtype=['core','player', 'player2'], priority = [166,25,0] )
|
Color Management, Stage 2: Switch color pipeline to use OpenColorIO
Replace old color pipeline which was supporting linear/sRGB color spaces
only with OpenColorIO-based pipeline.
This introduces two configurable color spaces:
- Input color space for images and movie clips. This space is used to convert
images/movies from color space in which file is saved to Blender's linear
space (for float images, byte images are not internally converted, only input
space is stored for such images and used later).
This setting could be found in image/clip data block settings.
- Display color space which defines space in which particular display is working.
This settings could be found in scene's Color Management panel.
When render result is being displayed on the screen, apart from converting image
to display space, some additional conversions could happen.
This conversions are:
- View, which defines tone curve applying before display transformation.
These are different ways to view the image on the same display device.
For example it could be used to emulate film view on sRGB display.
- Exposure affects on image exposure before tone map is applied.
- Gamma is post-display gamma correction, could be used to match particular
display gamma.
- RGB curves are user-defined curves which are applying before display
transformation, could be used for different purposes.
All this settings by default are only applying on render result and does not
affect on other images. If some particular image needs to be affected by this
transformation, "View as Render" setting of image data block should be set to
truth. Movie clips are always affected by all display transformations.
This commit also introduces configurable color space in which sequencer is
working. This setting could be found in scene's Color Management panel and
it should be used if such stuff as grading needs to be done in color space
different from sRGB (i.e. when Film view on sRGB display is use, using VD16
space as sequencer's internal space would make grading working in space
which is close to the space using for display).
Some technical notes:
- Image buffer's float buffer is now always in linear space, even if it was
created from 16bit byte images.
- Space of byte buffer is stored in image buffer's rect_colorspace property.
- Profile of image buffer was removed since it's not longer meaningful.
- OpenGL and GLSL is supposed to always work in sRGB space. It is possible
to support other spaces, but it's quite large project which isn't so
much important.
- Legacy Color Management option disabled is emulated by using None display.
It could have some regressions, but there's no clear way to avoid them.
- If OpenColorIO is disabled on build time, it should make blender behaving
in the same way as previous release with color management enabled.
More details could be found at this page (more details would be added soon):
http://wiki.blender.org/index.php/Dev:Ref/Release_Notes/2.64/Color_Management
--
Thanks to Xavier Thomas, Lukas Toene for initial work on OpenColorIO
integration and to Brecht van Lommel for some further development and code/
usecase review!
2012-09-15 10:05:07 +00:00
|
|
|
|
|
|
|
env.BlenderLib ( libname = 'bf_blenkernel_mask', sources = sources_mask, includes = Split(incs), defines = defs, libtype=['core','player', 'player2'], priority = [200,25,0] )
|