2013-06-03 67 views

回答

1

該手冊是我發現的最好的參考,除了谷歌搜索特定的解決方案。如果你深入進去,還有包括在模塊的網頁的一些體面的例子,像這裏的圖片模塊: http://effbot.org/imagingbook/image.htm

我不認爲你的意思是API,順便說一句,因爲PIL本身是一種編程接口。

0

我建議你去函數本身的源代碼看看如何使用每個函數的參數(不是最好的解決方案,但它是東西)。例如,你會看到類似的東西:

def point(self, lut, mode=None): 
    """ 
    Maps this image through a lookup table or function. 

    :param lut: A lookup table, containing 256 (or 65336 if 
     self.mode=="I" and mode == "L") values per band in the 
     image. A function can be used instead, it should take a 
     single argument. The function is called once for each 
     possible pixel value, and the resulting table is applied to 
     all bands of the image. 
    :param mode: Output mode (default is same as input). In the 
     current version, this can only be used if the source image 
     has mode "L" or "P", and the output has mode "1" or the 
     source image mode is "I" and the output mode is "L". 
    :returns: An :py:class:`~PIL.Image.Image` object. 
    """ 

如果您使用的是Eclipse,您可以使用F3導航到一個函數。