91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 13.64MB
    文件類型: .zip
    金幣: 1
    下載: 0 次
    發布日期: 2023-08-05
  • 語言: 其他
  • 標簽: 開源??

資源簡介

libvips, 一種低內存需求的快速圖像處理 libvips: 圖像處理庫 libvips是一個 2D 圖像處理庫。 類似的庫相比, libvips運行迅速,并且占用了很少的內存。 libvips許可于 LGPL 2.1 + 。它有 300個操作覆蓋算術,直方圖,卷積,形

資源截圖

代碼片段和文件信息

#!/usr/bin/python

#?walk?vips?and?generate?member?definitions?for?all?operators

#?sample?member?definition:

#?VImage?VImage::invert(?VOption?*options?)
#?{
#? VImage?out;
#?
#? call(?“invert“?
#? (options???options?:?VImage::option())->?
#? set(?“in“?*this?)->
#? set(?“out“?&out?)?);
#?
#? return(?out?);
#?}

import?sys
import?re

import?logging
#logging.basicConfig(level?=?logging.DEBUG)

import?gi
gi.require_version(‘Vips‘?‘8.0‘)
from?gi.repository?import?Vips?Gobject

vips_type_image?=?Gobject.GType.from_name(“VipsImage“)
vips_type_operation?=?Gobject.GType.from_name(“VipsOperation“)
param_enum?=?Gobject.GType.from_name(“GParamEnum“)

#?turn?a?GType?into?a?C++?type
gtype_to_cpp?=?{
????“VipsImage“?:?“VImage“
????“gint“?:?“int“
????“gdouble“?:?“double“
????“gboolean“?:?“bool“
????“gchararray“?:?“char?*“
????“VipsArrayInt“?:?“std::vector
????“VipsArrayDouble“?:?“std::vector
????“VipsArrayImage“?:?“std::vector
????“VipsBlob“?:?“VipsBlob?*“
}

def?get_ctype(prop):
????#?enum?params?use?the?C?name?as?their?name
????if?Gobject.type_is_a(param_enum?prop):
????????return?prop.value_type.name

????return?gtype_to_cpp[prop.value_type.name]

def?find_required(op):
????required?=?[]
????for?prop?in?op.props:
????????flags?=?op.get_argument_flags(prop.name)
????????if?not?flags?&?Vips.ArgumentFlags.REQUIRED:
????????????continue
????????if?flags?&?Vips.ArgumentFlags.DEPRECATED:
????????????continue

????????required.append(prop)

????def?priority_sort(a?b):
????????pa?=?op.get_argument_priority(a.name)
????????pb?=?op.get_argument_priority(b.name)

????????return?pa?-?pb

????required.sort(priority_sort)

????return?required

#?find?the?first?input?image?...?this?will?be?used?as?“this“
def?find_first_input_image(op?required):
????found?=?False
????for?prop?in?required:
????????flags?=?op.get_argument_flags(prop.name)
????????if?not?flags?&?Vips.ArgumentFlags.INPUT:
????????????continue
????????if?Gobject.type_is_a(vips_type_image?prop.value_type):
????????????found?=?True
????????????break

????if?not?found:
????????return?None

????return?prop

#?find?the?first?output?arg?...?this?will?be?used?as?the?result
def?find_first_output(op?required):
????found?=?False
????for?prop?in?required:
????????flags?=?op.get_argument_flags(prop.name)
????????if?not?flags?&?Vips.ArgumentFlags.OUTPUT:
????????????continue
????????found?=?True
????????break

????if?not?found:
????????return?None

????return?prop

#?swap?any?“-“?for?“_“
def?cppize(name):
????return?re.sub(‘-‘?‘_‘?name)

def?gen_arg_list(op?required):
????first?=?True
????for?prop?in?required:
????????if?not?first:
????????????print?‘‘
????????else:
????????????first?=?False

????????print?get_ctype(prop)

????????#?output?params?are?passed?by?reference
????????flags?=?op.get_argument_flags(prop.name)
????????if?flags?&?Vips.ArgumentFlags.OUTPUT:
????????????print?‘*‘

????????print?cppize(prop.name)

????if?not?first:
????????print?‘‘
????print?‘VOpt

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-10-29?13:29??libvips-master\
?????文件?????????132??2018-10-29?13:29??libvips-master\.gitattributes
?????文件????????2859??2018-10-29?13:29??libvips-master\.gitignore
?????文件????????2090??2018-10-29?13:29??libvips-master\.travis.yml
?????文件?????????978??2018-10-29?13:29??libvips-master\AUTHORS
?????文件???????26530??2018-10-29?13:29??libvips-master\COPYING
?????文件??????128495??2018-10-29?13:29??libvips-master\ChangeLog
?????文件???????15749??2018-10-29?13:29??libvips-master\INSTALL
?????文件????????1178??2018-10-29?13:29??libvips-master\Makefile.am
?????文件????????9331??2018-10-29?13:29??libvips-master\NEWS
?????文件???????10309??2018-10-29?13:29??libvips-master\README.md
?????文件?????????491??2018-10-29?13:29??libvips-master\THANKS
?????文件???????10571??2018-10-29?13:29??libvips-master\TODO
?????文件????????1995??2018-10-29?13:29??libvips-master\autogen.sh
?????目錄???????????0??2018-10-29?13:29??libvips-master\benchmark\
?????文件?????????522??2018-10-29?13:29??libvips-master\benchmark\README
?????文件????????1269??2018-10-29?13:29??libvips-master\benchmark\benchmarkn-osx.sh
?????文件????????1564??2018-10-29?13:29??libvips-master\benchmark\benchmarkn.sh
?????文件??????512784??2018-10-29?13:29??libvips-master\benchmark\sample2.v
?????文件???????42990??2018-10-29?13:29??libvips-master\configure.ac
?????目錄???????????0??2018-10-29?13:29??libvips-master\cplusplus\
?????文件?????????806??2018-10-29?13:29??libvips-master\cplusplus\Makefile.am
?????文件?????????136??2018-10-29?13:29??libvips-master\cplusplus\README
?????文件????????1286??2018-10-29?13:29??libvips-master\cplusplus\VError.cpp
?????文件???????27921??2018-10-29?13:29??libvips-master\cplusplus\VImage.cpp
?????文件????????1724??2018-10-29?13:29??libvips-master\cplusplus\VInterpolate.cpp
?????目錄???????????0??2018-10-29?13:29??libvips-master\cplusplus\examples\
?????文件?????????470??2018-10-29?13:29??libvips-master\cplusplus\examples\avg.cpp
?????文件?????????958??2018-10-29?13:29??libvips-master\cplusplus\examples\buffer.cpp
?????文件?????????523??2018-10-29?13:29??libvips-master\cplusplus\examples\embed.cpp
?????文件?????????669??2018-10-29?13:29??libvips-master\cplusplus\examples\invert.cpp
............此處省略756個文件信息

評論

共有 條評論