This function is useful when working with Ming, as SWFBitmap constructor will use a NON INTERLACED Jpeg file, so you have to use imageinterlace(0);
![]() | imageinterlace说明int imageinterlace ( resource image [, int interlace] )imageinterlace() 打开或关闭隔行扫描的比特标记。如果 interlace 为 1 则图像为隔行扫描的,如果 interlace 为 0 则图像为非隔行扫描的。 如果设定了隔行扫描比特标记而图像使用 JPEG 格式,则图像被创建为渐进式 JPEG。 本函数返回图像中是否设定了隔行扫描比特标记。 ![]()
julien / at / theoconcept.com
30-Jan-2006 06:33
This function is useful when working with Ming, as SWFBitmap constructor will use a NON INTERLACED Jpeg file, so you have to use imageinterlace(0);
mangobrain.co.uk
17-Jan-2006 06:03
dr_snapid's comment that "the server sends every Nth line" is not entirely true. A web server need not know anything about the contents of the file it is sending; its job is simply to send the data. Rather, the image is created in such a way that the data corresponding to "every Nth line" appears at the beginning of the file, with the details becoming able to be filled in as more of the file is received by the browser. In PHP's case, the data may have been generated dynamically instead of pulled from a file, but this does not change the fact that it is the data itself that is different, not the manner in which it is sent.*
dr_snapid at mxm dot com dot au
22-Nov-2005 12:16
Interlacing doesnt store another image, it simple changes the order in which the images lines are sent and rendered. The server sends every Nth line, reaches the end, then goes back to the start, reading the lines in between.
thomas dot brandl at barff dot de
15-Jul-2005 03:28
Set imageinterlace() to 0 if you need to load the generated images in Flash. Flash does not support progressive JPEGs
drake127
12-Jun-2005 06:51
Interlancing works also with PNG files but it increase filesize (from 14.4M to 17.7M).
mironto at mironto dot sk
19-Nov-2004 10:17
just to add my 5 cents on the progressive principle of jpeg: there are no several lowres images stored in jpeg along with original picture, the only thing altered is the order of "pixels". in jpeg the image is divided in areas 8x8 pixels, so instead of linear order of pixels (row-by-row), first there is one pixel form each 8x8 area included in the begining of the image data stream, so when the browser recieves all 8x8 area pixels, it can display "pixelate" image and as soon as it recieves more data, the browser can add more pixels and "sharpen" the image.
manuel.warum at edu.uni-klu.ac.at
16-Apr-2004 01:41
About MichaelSoft's note "Imageinterlace($im, 1) creates a JPG which is first loaded completely before showing anything":
ben dash xo at dubplates dot org
19-Mar-2004 10:25
There is a bug in Microsoft Internet Explorer (at least at present) that means that often, a progressive/interlaced JPEG will actually NOT show at all whilst loading, suddenly appearing only when the entire picture has loaded. A regular NON-interlaced/NON-progressive JPEG will display line by line as it loads, which paradoxically gives the illusion that it's loading faster. MSIE definitely has this one backwards!!
PHPProgrammer
24-Nov-2003 10:21
Using the interlace-option reduces the filesize! (doesnt really match with the idea that an additional low-res-image is stored)
| ![]() |