19 |
* along with this program ; if not, write to the Free Software |
* along with this program ; if not, write to the Free Software |
20 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
21 |
* |
* |
22 |
* $Id: image.c,v 1.26.2.7 2003-06-09 13:53:50 edgomez Exp $ |
* $Id: image.c,v 1.26.2.8 2003-08-25 15:01:51 edgomez Exp $ |
23 |
* |
* |
24 |
****************************************************************************/ |
****************************************************************************/ |
25 |
|
|
131 |
uint32_t height) |
uint32_t height) |
132 |
{ |
{ |
133 |
const uint32_t edged_width2 = edged_width / 2; |
const uint32_t edged_width2 = edged_width / 2; |
134 |
const uint32_t width2 = width / 2; |
uint32_t width2; |
135 |
uint32_t i; |
uint32_t i; |
136 |
uint8_t *dst; |
uint8_t *dst; |
137 |
uint8_t *src; |
uint8_t *src; |
140 |
dst = image->y - (EDGE_SIZE + EDGE_SIZE * edged_width); |
dst = image->y - (EDGE_SIZE + EDGE_SIZE * edged_width); |
141 |
src = image->y; |
src = image->y; |
142 |
|
|
143 |
|
/* According to the Standard Clause 7.6.4, padding is done starting at 16 |
144 |
|
* pixel width and height multiples */ |
145 |
|
width = (width+15)&~15; |
146 |
|
height = (height+15)&~15; |
147 |
|
width2 = width/2; |
148 |
|
|
149 |
for (i = 0; i < EDGE_SIZE; i++) { |
for (i = 0; i < EDGE_SIZE; i++) { |
150 |
memset(dst, *src, EDGE_SIZE); |
memset(dst, *src, EDGE_SIZE); |
151 |
memcpy(dst + EDGE_SIZE, src, width); |
memcpy(dst + EDGE_SIZE, src, width); |