2013-05-20 22:15:32 +00:00
|
|
|
# GYP file for images project.
|
2013-04-17 21:07:55 +00:00
|
|
|
{
|
2011-05-31 13:50:51 +00:00
|
|
|
'targets': [
|
|
|
|
{
|
|
|
|
'target_name': 'images',
|
2012-10-10 19:45:51 +00:00
|
|
|
'product_name': 'skia_images',
|
2011-05-31 13:50:51 +00:00
|
|
|
'type': 'static_library',
|
2012-10-10 19:45:51 +00:00
|
|
|
'standalone_static_library': 1,
|
2011-06-23 21:43:52 +00:00
|
|
|
'dependencies': [
|
2013-07-22 14:39:45 +00:00
|
|
|
'core.gyp:*',
|
2012-04-05 14:52:01 +00:00
|
|
|
'libjpeg.gyp:*',
|
2013-03-14 14:42:18 +00:00
|
|
|
'libwebp.gyp:libwebp',
|
2011-06-23 21:43:52 +00:00
|
|
|
'utils.gyp:utils',
|
|
|
|
],
|
2012-04-05 14:52:01 +00:00
|
|
|
'export_dependent_settings': [
|
|
|
|
'libjpeg.gyp:*',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
'include_dirs': [
|
|
|
|
'../include/images',
|
2013-02-22 21:38:35 +00:00
|
|
|
'../include/lazy',
|
2013-04-25 17:33:51 +00:00
|
|
|
# for access to SkErrorInternals.h
|
|
|
|
'../src/core/',
|
2013-02-22 21:38:35 +00:00
|
|
|
# for access to SkImagePriv.h
|
|
|
|
'../src/image/',
|
2013-08-28 19:13:13 +00:00
|
|
|
# So src/ports/SkImageDecoder_CG can access SkStreamHelpers.h
|
|
|
|
'../src/images/',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'sources': [
|
2013-05-31 14:00:10 +00:00
|
|
|
'../include/images/SkForceLinking.h',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../include/images/SkImageRef.h',
|
|
|
|
'../include/images/SkImageRef_GlobalPool.h',
|
2013-03-22 16:44:14 +00:00
|
|
|
'../src/images/SkJpegUtility.h',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../include/images/SkMovie.h',
|
|
|
|
'../include/images/SkPageFlipper.h',
|
|
|
|
|
|
|
|
'../src/images/bmpdecoderhelper.cpp',
|
|
|
|
'../src/images/bmpdecoderhelper.h',
|
2013-03-14 14:42:18 +00:00
|
|
|
|
2013-05-31 14:00:10 +00:00
|
|
|
'../src/images/SkForceLinking.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageDecoder.cpp',
|
2013-04-17 21:07:55 +00:00
|
|
|
'../src/images/SkImageDecoder_FactoryDefault.cpp',
|
|
|
|
'../src/images/SkImageDecoder_FactoryRegistrar.cpp',
|
2013-05-01 21:17:27 +00:00
|
|
|
# If decoders are added/removed to/from (all/individual)
|
2013-05-31 14:00:10 +00:00
|
|
|
# platform(s), be sure to update SkForceLinking.cpp
|
2013-05-01 21:17:27 +00:00
|
|
|
# so the right decoders will be forced to link.
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageDecoder_libbmp.cpp',
|
|
|
|
'../src/images/SkImageDecoder_libgif.cpp',
|
|
|
|
'../src/images/SkImageDecoder_libico.cpp',
|
2013-03-14 14:42:18 +00:00
|
|
|
'../src/images/SkImageDecoder_libjpeg.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageDecoder_libpng.cpp',
|
2013-03-14 14:42:18 +00:00
|
|
|
'../src/images/SkImageDecoder_libwebp.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageDecoder_wbmp.cpp',
|
|
|
|
'../src/images/SkImageEncoder.cpp',
|
|
|
|
'../src/images/SkImageEncoder_Factory.cpp',
|
2013-04-23 18:06:23 +00:00
|
|
|
'../src/images/SkImageEncoder_argb.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageRef.cpp',
|
|
|
|
'../src/images/SkImageRefPool.cpp',
|
|
|
|
'../src/images/SkImageRefPool.h',
|
2013-02-01 15:57:13 +00:00
|
|
|
'../src/images/SkImageRef_ashmem.h',
|
|
|
|
'../src/images/SkImageRef_ashmem.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageRef_GlobalPool.cpp',
|
Add the ability to provide function pointers to SkPicture serialization
and deserialization for encoding and decoding bitmaps.
Remove kForceFlattenBitmapPixels_Flag, which is no longer used.
When an SkOrderedReadBuffer needs to read a bitmap, if it does not
have an image decoder, use a dummy bitmap.
In GM, add a tolerance option for color differences, used when
testing picture serialization, so it can assume two images are the
same even though PNG encoding/decoding may have resulted in small
differences.
Create dummy implementations for SkImageDecoder and SkImageEncoder
functions in SkImageDecoder_empty so that a project that does not
want to include the images project it can still build.
Allow ports to build without images project.
In Mac's image encoder, copy 4444 to 8888 before encoding.
Add SkWriter32::reservePad, to provide a pointer to write non 4 byte
aligned data, padded with zeroes.
In bench_ and render_ pictures, pass decode function to SkPicture
creation from a stream.
BUG=https://code.google.com/p/skia/issues/detail?id=842
Review URL: https://codereview.appspot.com/6551071
git-svn-id: http://skia.googlecode.com/svn/trunk@5818 2bbb7eff-a529-9590-31e7-b0007b416f81
2012-10-04 21:46:08 +00:00
|
|
|
'../src/images/SkImages.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkJpegUtility.cpp',
|
|
|
|
'../src/images/SkMovie.cpp',
|
|
|
|
'../src/images/SkMovie_gif.cpp',
|
|
|
|
'../src/images/SkPageFlipper.cpp',
|
|
|
|
'../src/images/SkScaledBitmapSampler.cpp',
|
|
|
|
'../src/images/SkScaledBitmapSampler.h',
|
2013-08-21 15:01:48 +00:00
|
|
|
'../src/images/SkStreamHelpers.cpp',
|
|
|
|
'../src/images/SkStreamHelpers.h',
|
2011-06-22 20:42:34 +00:00
|
|
|
|
|
|
|
'../src/ports/SkImageDecoder_CG.cpp',
|
|
|
|
'../src/ports/SkImageDecoder_WIC.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'conditions': [
|
2011-07-01 20:20:07 +00:00
|
|
|
[ 'skia_os == "win"', {
|
2011-05-31 13:50:51 +00:00
|
|
|
'sources!': [
|
2013-04-17 21:07:55 +00:00
|
|
|
'../src/images/SkImageDecoder_FactoryDefault.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageDecoder_libgif.cpp',
|
|
|
|
'../src/images/SkImageDecoder_libpng.cpp',
|
|
|
|
'../src/images/SkMovie_gif.cpp',
|
|
|
|
],
|
2011-11-21 21:04:06 +00:00
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'windowscodecs.lib',
|
|
|
|
],
|
|
|
|
},
|
2011-07-01 20:20:07 +00:00
|
|
|
},{ #else if skia_os != win
|
2011-06-22 20:42:34 +00:00
|
|
|
'sources!': [
|
|
|
|
'../src/ports/SkImageDecoder_WIC.cpp',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
}],
|
2012-09-18 15:41:18 +00:00
|
|
|
[ 'skia_os in ["mac", "ios"]', {
|
2011-05-31 13:50:51 +00:00
|
|
|
'sources!': [
|
2013-04-17 21:07:55 +00:00
|
|
|
'../src/images/SkImageDecoder_FactoryDefault.cpp',
|
2011-06-15 17:33:29 +00:00
|
|
|
'../src/images/SkImageDecoder_libpng.cpp',
|
2011-05-31 13:50:51 +00:00
|
|
|
'../src/images/SkImageDecoder_libgif.cpp',
|
|
|
|
'../src/images/SkMovie_gif.cpp',
|
|
|
|
],
|
2011-07-01 20:20:07 +00:00
|
|
|
},{ #else if skia_os != mac
|
2011-06-22 20:42:34 +00:00
|
|
|
'sources!': [
|
|
|
|
'../src/ports/SkImageDecoder_CG.cpp',
|
|
|
|
],
|
2011-05-31 13:50:51 +00:00
|
|
|
}],
|
2013-04-11 22:24:35 +00:00
|
|
|
[ 'skia_os in ["linux", "freebsd", "openbsd", "solaris"]', {
|
2013-04-11 18:32:01 +00:00
|
|
|
# Any targets that depend on this target should link in libpng, libgif, and
|
2011-06-15 13:45:10 +00:00
|
|
|
# our code that calls it.
|
|
|
|
# See http://code.google.com/p/gyp/wiki/InputFormatReference#Dependent_Settings
|
2011-06-02 14:38:23 +00:00
|
|
|
'link_settings': {
|
2011-06-16 12:27:14 +00:00
|
|
|
'libraries': [
|
2013-04-11 18:32:01 +00:00
|
|
|
'-lgif',
|
2011-06-16 12:27:14 +00:00
|
|
|
'-lpng',
|
2013-03-07 15:33:28 +00:00
|
|
|
'-lz',
|
2011-06-16 12:27:14 +00:00
|
|
|
],
|
2011-06-02 14:38:23 +00:00
|
|
|
},
|
2013-04-11 18:32:01 +00:00
|
|
|
# end libpng/libgif stuff
|
2011-05-31 13:50:51 +00:00
|
|
|
}],
|
2013-04-11 22:24:35 +00:00
|
|
|
# FIXME: NaCl should be just like linux, etc, above, but it currently is separated out
|
|
|
|
# to remove gif. Once gif is supported by naclports, this can be merged into the above
|
|
|
|
# condition.
|
|
|
|
[ 'skia_os == "nacl"', {
|
|
|
|
'sources!': [
|
|
|
|
'../src/images/SkImageDecoder_libgif.cpp',
|
|
|
|
'../src/images/SkMovie_gif.cpp',
|
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lpng',
|
|
|
|
'-lz',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2011-11-03 13:08:29 +00:00
|
|
|
[ 'skia_os == "android"', {
|
2013-02-01 15:57:13 +00:00
|
|
|
'include_dirs': [
|
|
|
|
'../src/utils',
|
2011-11-03 13:08:29 +00:00
|
|
|
],
|
|
|
|
'dependencies': [
|
2012-08-09 15:54:28 +00:00
|
|
|
'android_deps.gyp:gif',
|
|
|
|
'android_deps.gyp:png',
|
2011-11-03 13:08:29 +00:00
|
|
|
],
|
2013-07-23 15:51:12 +00:00
|
|
|
'export_dependent_settings': [
|
|
|
|
'android_deps.gyp:png'
|
|
|
|
],
|
2013-02-01 15:57:13 +00:00
|
|
|
},{ #else if skia_os != android
|
|
|
|
'sources!': [
|
|
|
|
'../src/images/SkImageRef_ashmem.h',
|
|
|
|
'../src/images/SkImageRef_ashmem.cpp',
|
|
|
|
],
|
2011-11-03 13:08:29 +00:00
|
|
|
}],
|
2013-06-11 15:52:19 +00:00
|
|
|
[ 'skia_os == "chromeos"', {
|
|
|
|
'dependencies': [
|
|
|
|
'chromeos_deps.gyp:gif',
|
|
|
|
],
|
|
|
|
'link_settings': {
|
|
|
|
'libraries': [
|
|
|
|
'-lpng',
|
|
|
|
],
|
|
|
|
},
|
|
|
|
}],
|
2012-09-18 15:41:18 +00:00
|
|
|
[ 'skia_os == "ios"', {
|
|
|
|
'include_dirs': [
|
|
|
|
'../include/utils/mac',
|
|
|
|
],
|
|
|
|
}],
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
'direct_dependent_settings': {
|
|
|
|
'include_dirs': [
|
|
|
|
'../include/images',
|
2013-02-22 21:38:35 +00:00
|
|
|
'../include/lazy',
|
2011-05-31 13:50:51 +00:00
|
|
|
],
|
|
|
|
},
|
|
|
|
},
|
|
|
|
],
|
|
|
|
}
|
|
|
|
|
|
|
|
# Local Variables:
|
|
|
|
# tab-width:2
|
|
|
|
# indent-tabs-mode:nil
|
|
|
|
# End:
|
|
|
|
# vim: set expandtab tabstop=2 shiftwidth=2:
|