Rev 6891 | Rev 8341 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 6891 | Rev 7279 | ||
---|---|---|---|
Line 2142... | Line 2142... | ||
2142 | 2142 | ||
Line 2143... | Line 2143... | ||
2143 | mov eax,[edx+png_image.format] |
2143 | mov eax,[edx+png_image.format] |
2144 | and eax,PNG_FORMAT_FLAG_ALPHA |
2144 | and eax,PNG_FORMAT_FLAG_ALPHA |
2145 | jz .end0 ;if (..!=0) |
2145 | jz .end0 ;if (..!=0) |
2146 | ; bytep row_end; |
- | |
2147 | ; int aindex; |
- | |
Line 2148... | Line 2146... | ||
2148 | 2146 | ||
- | 2147 | if PNG_SIMPLIFIED_WRITE_AFIRST_SUPPORTED eq 1 |
|
2149 | if PNG_SIMPLIFIED_WRITE_AFIRST_SUPPORTED eq 1 |
2148 | mov eax,[edx+png_image.format] |
2150 | ; if ((image->format & PNG_FORMAT_FLAG_AFIRST) != 0) |
2149 | and eax,PNG_FORMAT_FLAG_AFIRST |
2151 | ; { |
2150 | jz .end2 ;if (..!=0) |
2152 | ; aindex = -1; |
2151 | mov [aindex],-1 |
2153 | ; ++input_row; /* To point to the first component */ |
2152 | inc [input_row] ; To point to the first component |
2154 | ; ++output_row; |
2153 | inc [output_row] |
2155 | ; } |
- | |
2156 | 2154 | jmp @f |
|
2157 | ; else |
2155 | .end2: ;else |
2158 | end if |
2156 | end if |
- | 2157 | mov eax,[channels] |
|
- | 2158 | mov [aindex],eax |
|
Line 2159... | Line 2159... | ||
2159 | ; aindex = channels; |
2159 | .@@: |
- | 2160 | ||
- | 2161 | ; Use row_end in place of a loop counter: |
|
2160 | 2162 | mov ecx,[channels] |
|
- | 2163 | inc ecx |
|
- | 2164 | imul ecx,[edx+png_image.width] |
|
Line 2161... | Line 2165... | ||
2161 | ; Use row_end in place of a loop counter: |
2165 | add ecx,[output_row] |
2162 | ; row_end = output_row + image->width * (channels+1); |
2166 | ;ecx = row_end |
2163 | 2167 | ||
2164 | ; while (y-- > 0) |
2168 | ; while (y-- > 0) |
Line 2753... | Line 2757... | ||
2753 | ; supported by the rest of the libpng write code; call it directly. |
2757 | ; supported by the rest of the libpng write code; call it directly. |
2754 | 2758 | ||
Line 2755... | Line 2759... | ||
2755 | .end9: ;else |
2759 | .end9: ;else |
2756 | if 1 ;;; IDAT compress all (only 24 bit) |
2760 | if 1 ;;; IDAT compress all (only 24 bit) |
- | 2761 | cmp dword[ebx+png_image.height],1 |
|
- | 2762 | jl .end8 |
|
2757 | mov ecx,[edx+png_image_write_control.row_bytes] |
2763 | mov ecx,[edx+png_image_write_control.row_bytes] |
2758 | inc ecx |
2764 | inc ecx |
2759 | imul ecx,[ebx+png_image.height] |
2765 | imul ecx,[ebx+png_image.height] |
2760 | cmp ecx,1 |
- | |
2761 | jl .end8 |
- | |
2762 | stdcall create_compress_IDAT, edi, [edx+png_image_write_control.first_row], ecx, [ebx+png_image.width], [ebx+png_image.height] |
2766 | stdcall create_compress_IDAT, edi, [edx+png_image_write_control.first_row], ecx, [ebx+png_image.width], [ebx+png_image.height] |
2763 | else ;;; IDAT compress by lines |
2767 | else ;;; IDAT compress by lines |
2764 | mov ecx,[ebx+png_image.height] |
2768 | mov ecx,[ebx+png_image.height] |
2765 | cmp ecx,1 |
2769 | cmp ecx,1 |
2766 | jl .end8 |
2770 | jl .end8 |