mirror of
https://github.com/YACReader/yacreader
synced 2025-07-18 13:04:28 -04:00
Corregido bug en yacreader_flow_gl: abs -> fabs, para evitar conversi?n de float a int al compilar con gcc.
Corregida traducci?n en el di?logo crear biblioteca.
This commit is contained in:
Binary file not shown.
@ -180,7 +180,7 @@
|
|||||||
<message>
|
<message>
|
||||||
<location filename="create_library_dialog.cpp" line="66"/>
|
<location filename="create_library_dialog.cpp" line="66"/>
|
||||||
<source>Create a library could take several minutes. You can stop the process and update the library later for completing the task.</source>
|
<source>Create a library could take several minutes. You can stop the process and update the library later for completing the task.</source>
|
||||||
<translation>Crear una biblioteca puede llevar varios minutos. Puedesde parar el proceso en cualquier momento y completar la tarea más tarde.</translation>
|
<translation>Crear una biblioteca puede llevar varios minutos. Puedes parar el proceso en cualquier momento y completar la tarea más tarde.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="create_library_dialog.cpp" line="91"/>
|
<location filename="create_library_dialog.cpp" line="91"/>
|
||||||
|
@ -2,10 +2,11 @@
|
|||||||
|
|
||||||
#include <QtGui>
|
#include <QtGui>
|
||||||
#include <QtOpenGL>
|
#include <QtOpenGL>
|
||||||
#include <math.h>
|
//#include <math.h>
|
||||||
#include <GL/glu.h>
|
#include <GL/glu.h>
|
||||||
#include <QGLContext>
|
#include <QGLContext>
|
||||||
#include <QGLPixelBuffer>
|
#include <QGLPixelBuffer>
|
||||||
|
#include <cmath>
|
||||||
|
|
||||||
/*** Animation Settings ***/
|
/*** Animation Settings ***/
|
||||||
|
|
||||||
@ -351,7 +352,7 @@ void YACReaderFlowGL::animate(RVect *Current,RVect to)
|
|||||||
Current->y = Current->y+(to.y-Current->y)*config.animationStep;
|
Current->y = Current->y+(to.y-Current->y)*config.animationStep;
|
||||||
Current->z = Current->z+(to.z-Current->z)*config.animationStep;
|
Current->z = Current->z+(to.z-Current->z)*config.animationStep;
|
||||||
|
|
||||||
if(abs(to.rot-Current->rot) > 0.01){
|
if(fabs(to.rot-Current->rot) > 0.01){
|
||||||
Current->rot = Current->rot+(to.rot-Current->rot)*(config.animationStep*config.preRotation);
|
Current->rot = Current->rot+(to.rot-Current->rot)*(config.animationStep*config.preRotation);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -364,7 +365,7 @@ void YACReaderFlowGL::drawCover(CFImage *CF)
|
|||||||
float h = CF->height;
|
float h = CF->height;
|
||||||
|
|
||||||
//fadeout
|
//fadeout
|
||||||
float opacity = 1-1/(config.animationFadeOutDist+config.viewRotateLightStrenght*abs(viewRotate))*abs(0-CF->current.x);
|
float opacity = 1-1/(config.animationFadeOutDist+config.viewRotateLightStrenght*fabs(viewRotate))*fabs(0-CF->current.x);
|
||||||
|
|
||||||
glLoadIdentity();
|
glLoadIdentity();
|
||||||
glTranslatef(config.cfX,config.cfY,config.cfZ);
|
glTranslatef(config.cfX,config.cfY,config.cfZ);
|
||||||
@ -601,7 +602,7 @@ void YACReaderFlowGL::updatePositions()
|
|||||||
viewRotate += (0-viewRotate)*config.viewRotateSub;
|
viewRotate += (0-viewRotate)*config.viewRotateSub;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(abs (cfImages[currentSelected].current.x - cfImages[currentSelected].animEnd.x) < 1)//viewRotate < 0.2)
|
if(fabs (cfImages[currentSelected].current.x - cfImages[currentSelected].animEnd.x) < 1)//viewRotate < 0.2)
|
||||||
{
|
{
|
||||||
cleanupAnimation();
|
cleanupAnimation();
|
||||||
if(updateCount >= 0) //TODO parametrizar
|
if(updateCount >= 0) //TODO parametrizar
|
||||||
|
Reference in New Issue
Block a user