Changeset 18625
- Timestamp:
- 11/17/12 14:50:08 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
titan/titan/global.h
r18571 r18625 2594 2594 { 2595 2595 int ret = 0; 2596 int leftoffset = status.leftoffset; 2597 int rightoffset = status.rightoffset; 2598 int topoffset = status.topoffset; 2599 int bottomoffset = status.bottomoffset; 2600 2601 float rx = (float)fb->width / 720; 2602 float ry = (float)fb->height / 576; 2603 2604 leftoffset = (float)leftoffset / rx; 2605 rightoffset = (float)rightoffset / rx; 2606 topoffset = (float)topoffset / ry; 2607 bottomoffset = (float)bottomoffset / ry; 2608 2609 rx = (float)720 / (float)(720 - leftoffset - rightoffset); 2610 ry = (float)576 / (float)(576 - topoffset - bottomoffset); 2611 2612 posx = (float)posx / rx; 2613 posx += leftoffset; 2614 2615 posy = (float)posy / ry; 2616 posy += topoffset; 2596 2617 2597 2618 if(flag == 0) 2598 ret = setvmpeg(node, posx, posy, wh, wh / 1.2); 2619 { 2620 wh = ((float)wh / rx); 2621 ret = setvmpeg(node, posx, posy, wh, (int)((float)wh / 1.2)); 2622 } 2599 2623 2600 2624 if(flag == 1) 2601 ret = setvmpeg(node, posx, posy, wh * 1.2, wh); 2625 { 2626 wh = ((float)wh / ry); 2627 ret = setvmpeg(node, posx, posy, (int)((float)wh * 1.2), wh); 2628 } 2602 2629 2603 2630 return ret;
Note: See TracChangeset
for help on using the changeset viewer.