Changeset 23809
- Timestamp:
- 09/21/13 11:30:57 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
titan/titan/skin.h
r23808 r23809 93 93 if(ostrcmp("getplaytext", value) == 0) 94 94 return &getplaytext; 95 95 if(ostrcmp("getbufferstatus", value) == 0) 96 96 { 97 97 *rettype = FUNCPROGRESS; … … 133 133 return &getsignal; 134 134 } 135 135 if(ostrcmp("getrecfreesizetext", value) == 0) 136 136 return &getrecfreesizetext; 137 137 if(ostrcmp("getwlanlinkqualitytext", value) == 0) … … 1514 1514 int drawjpgsw(struct jpeg_decompress_struct* cinfo, unsigned char* buf, int posx, int posy, int width, int height, int colbytes, int mwidth, int mheight, int scalewidth, int scaleheight, int halign, int valign) 1515 1515 { 1516 int aktline = 0, x = 0, py = 0, px = 0, row_stride = 0; 1516 int aktline = 0, x = 0, py = 0, px = 0, row_stride = 0, pyw = 0; 1517 int width4 = width * 4, width8 = width * 8, aktline1 = 0; 1517 1518 unsigned char red, green, blue; 1518 1519 unsigned long color = 0; … … 1529 1530 row_stride = width * colbytes; 1530 1531 1531 if(accelfb != NULL && accelfb->varfbsize > width *8 && (scalewidth != 0 || scaleheight != 0) && (scalewidth != width || scaleheight != height))1532 if(accelfb != NULL && accelfb->varfbsize > width8 && (scalewidth != 0 || scaleheight != 0) && (scalewidth != width || scaleheight != height)) 1532 1533 { 1533 1534 if(halign == CENTER) … … 1554 1555 1555 1556 py++; 1557 pyw = width * py; 1556 1558 for(x = 0; x < width; x++) 1557 1559 { … … 1567 1569 color = (255 << 24) | (red << 16) | (red << 8) | red; 1568 1570 1569 drawpixelfb(accelfb, (width * py)+ x, 0, color);1571 drawpixelfb(accelfb, pyw + x, 0, color); 1570 1572 } 1571 1573 1572 if((py * width * 4) + (width *8) >= accelfb->varfbsize)1574 if((py * width4) + (width8) >= accelfb->varfbsize) 1573 1575 { 1574 1576 py++; … … 1591 1593 while(aktline < height) 1592 1594 { 1595 aktline1 = aktline * row_stride; 1593 1596 aktline++; 1594 1597 1595 1598 py++; 1599 pyw = width * py; 1596 1600 for(x = 0; x < width; x++) 1597 1601 { 1598 1602 px = colbytes * x; 1599 red = buf[ ((aktline - 1) * row_stride)+ px];1603 red = buf[aktline1 + px]; 1600 1604 if(colbytes > 2) 1601 1605 { 1602 green = buf[ ((aktline - 1) * row_stride)+ (px + 1)];1603 blue = buf[ ((aktline - 1) * row_stride)+ (px + 2)];1606 green = buf[aktline1 + (px + 1)]; 1607 blue = buf[aktline1 + (px + 2)]; 1604 1608 color = (255 << 24) | (red << 16) | (green << 8) | blue; 1605 1609 } … … 1607 1611 color = (255 << 24) | (red << 16) | (red << 8) | red; 1608 1612 1609 drawpixelfb(accelfb, (width * py)+ x, 0, color);1613 drawpixelfb(accelfb, pyw + x, 0, color); 1610 1614 } 1611 1615 1612 if((py * width * 4) + (width *8) >= accelfb->varfbsize)1616 if((py * width4) + (width8) >= accelfb->varfbsize) 1613 1617 { 1614 1618 py++; … … 1660 1664 else 1661 1665 aktline++; 1666 1667 aktline1 = (aktline - 1) * row_stride; 1662 1668 1663 1669 py = (posy + aktline - 1) * skinfb->width; … … 1669 1675 red = buffer[0][px]; 1670 1676 else 1671 red = buf[ ((aktline - 1) * row_stride)+ px];1677 red = buf[aktline1 + px]; 1672 1678 1673 1679 if(colbytes > 2) … … 1681 1687 else 1682 1688 { 1683 green = buf[ ((aktline - 1) * row_stride)+ (px + 1)];1684 blue = buf[ ((aktline - 1) * row_stride)+ (px + 2)];1689 green = buf[aktline1 + (px + 1)]; 1690 blue = buf[aktline1 + (px + 2)]; 1685 1691 color = (255 << 24) | (red << 16) | (green << 8) | blue; 1686 1692 }
Note: See TracChangeset
for help on using the changeset viewer.