readTiff(rtiff)
readTiff()所属R语言包:rtiff
A function to load TIFF images into a pixmap.
一个函数来加载TIFF图像成位图。
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Loads a TIFF image from a file and returns the image as a pixmap object, with optional scaling.
从文件加载一个TIFF图像传回的图像作为一个pixmap对象,与可选的扩展。
用法----------Usage----------
readTiff(fn, page = 0, reduce = 0)
参数----------Arguments----------
参数:fn
Filename (the tiff image to load)
文件名(TIFF图像加载)
参数:page
In the case of multi-page tiffs, which page do you want?
在的情况下,多页TIFF,这页你想要什么?
参数:reduce
Optional scaling factor to improve performance with large images, should be a value between 0 and 1 (i.e. a decimal representation of a percentage). See details.
可选的缩放因子,以提高性能与较大的图像,应该是0和1之间的一个数值(即十进制表示的百分比)。查看详细信息。
Details
详细信息----------Details----------
This package is a wrapper around libtiff (www.libtiff.org), on which it depends. By using libtiff's highlevel TIFFReadRGBAImage function, this package inherently support a wide range of image formats and compression schemes (interestingly, thanks to libtiff, this package can load a number of TIFF formats that tools like Window's Paint or the open source Gimp application will not load).
这个包是一个包装周围的libtiff(www.libtiff.org),它依赖。通过使用的libtiff的高层TIFFReadRGBAImage功能,这个包本质上支持范围广泛的图像格式和压缩计划(有趣的是,由于到的libtiff,这个包可以加载一个数的TIFF格式,Windows的画图或在开放的源瘸子应用等工具将不加载)。
High resolution images (by which I mean images that contain a "large" number of pixels) will occupy quite a bit of memory and will also plot very slowly. If you do not need all the resolution for your purposes, you scan specify a scaling factor (reduce=x) to downsample the image. The factor is the amount you want the image scaled BY, not TO. In otherwords, reduce=.90 will reduce the image by 90 yielding an image 10 approach is used. Since we are reducing and not enlarging, I hope this will be suitable for your applications.
高分辨率的图像(我指的是图像包含一个“大”的像素数)会占用相当多的内存,也将绘制速度非常缓慢。如果你并不需要所有的分辨率,你的目的,你扫描指定的缩放因子(减少= X)下取样图像。的因素是您所希望的图像缩放,都不到。换句话说,减少= .90,会降低图像产生图像的方法是使用90。由于我们正在减少,而不是扩大,我希望这将是适合你的应用程序。
For simplicity, an RGB pixmap is generated regardless of the colorspace of the original image (including grayscale images, in which case the R, G, and B rasters are identical). The pixmap object requires pixel intensities to be between 0 and 1, so the intensities in the orginal image file are scaled accordingly.
为简单起见,一个RGB的pixmap不管产生的原始图像的色彩空间(包括灰度图像,在这种情况下是相同的R,G,和B栅格)。的pixmap对象需要的像素强度是0和1之间,所以相应的缩放在原价的图像文件的的强度。
值----------Value----------
A pixmap object containing the image rasters.
一个pixmap对象,其中包含的图像栅格。
(作者)----------Author(s)----------
Eric Kort <eric.kort@vai.org>
实例----------Examples----------
tif <- readTiff(system.file("tiff", "jello.tif", package="rtiff"))
plot(tif)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|