forked from len0rd/rockbox
fix divide-by-zero error in pictureflow when selecting album
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19876 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
34b3fd9f61
commit
83350f2fed
1 changed files with 1 additions and 1 deletions
|
|
@ -1180,8 +1180,8 @@ void render_slide(struct slide_data *slide, const int alpha)
|
||||||
|
|
||||||
|
|
||||||
int distance = (h + slide->distance) * 100 / zoom;
|
int distance = (h + slide->distance) * 100 / zoom;
|
||||||
PFreal dist = distance * PFREAL_ONE;
|
|
||||||
if (distance < 100 ) distance = 100; /* clamp distances */
|
if (distance < 100 ) distance = 100; /* clamp distances */
|
||||||
|
PFreal dist = distance * PFREAL_ONE;
|
||||||
PFreal sdx = fcos(slide->angle);
|
PFreal sdx = fcos(slide->angle);
|
||||||
PFreal sdy = fsin(slide->angle);
|
PFreal sdy = fsin(slide->angle);
|
||||||
PFreal xs = slide->cx - sw * fdiv(sdx, dist) / 2;
|
PFreal xs = slide->cx - sw * fdiv(sdx, dist) / 2;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue