Aegisub/vsfilter/patchfiles/floatpos.patch

42 lines
1.6 KiB
Diff

Index: RTS.cpp
===================================================================
--- RTS.cpp (revision 611)
+++ RTS.cpp (working copy)
@@ -1724,10 +1738,10 @@
{
if(Effect* e = new Effect)
{
- e->param[0] = (int)(sub->m_scalex*wcstol(params[0], NULL, 10)*8);
- e->param[1] = (int)(sub->m_scaley*wcstol(params[1], NULL, 10)*8);
- e->param[2] = (int)(sub->m_scalex*wcstol(params[2], NULL, 10)*8);
- e->param[3] = (int)(sub->m_scaley*wcstol(params[3], NULL, 10)*8);
+ e->param[0] = (int)(sub->m_scalex*wcstod(params[0], NULL)*8);
+ e->param[1] = (int)(sub->m_scaley*wcstod(params[1], NULL)*8);
+ e->param[2] = (int)(sub->m_scalex*wcstod(params[2], NULL)*8);
+ e->param[3] = (int)(sub->m_scaley*wcstod(params[3], NULL)*8);
e->t[0] = e->t[1] = -1;
@@ -1747,8 +1761,8 @@
{
if(Effect* e = new Effect)
{
- e->param[0] = (int)(sub->m_scalex*wcstol(params[0], NULL, 10)*8);
- e->param[1] = (int)(sub->m_scaley*wcstol(params[1], NULL, 10)*8);
+ e->param[0] = (int)(sub->m_scalex*wcstod(params[0], NULL)*8);
+ e->param[1] = (int)(sub->m_scaley*wcstod(params[1], NULL)*8);
sub->m_effects[EF_ORG] = e;
}
@@ -1764,8 +1778,8 @@
{
if(Effect* e = new Effect)
{
- e->param[0] = e->param[2] = (int)(sub->m_scalex*wcstol(params[0], NULL, 10)*8);
- e->param[1] = e->param[3] = (int)(sub->m_scaley*wcstol(params[1], NULL, 10)*8);
+ e->param[0] = e->param[2] = (int)(sub->m_scalex*wcstod(params[0], NULL)*8);
+ e->param[1] = e->param[3] = (int)(sub->m_scaley*wcstod(params[1], NULL)*8);
e->t[0] = e->t[1] = 0;
sub->m_effects[EF_MOVE] = e;