From: Good Guy Date: Tue, 13 Nov 2018 14:19:10 +0000 (-0700) Subject: make kfrm share_lock recursive, dial back sketcher clamps X-Git-Tag: 2019-08~185 X-Git-Url: https://git.cinelerra-gg.org/git/?a=commitdiff_plain;h=fcffc409fe3f6909f4e5d9e105a1cbb5bc68eb5d;p=goodguy%2Fcinelerra.git make kfrm share_lock recursive, dial back sketcher clamps --- diff --git a/cinelerra-5.1/cinelerra/filexml.C b/cinelerra-5.1/cinelerra/filexml.C index 8b7315ca..58a83e9e 100644 --- a/cinelerra-5.1/cinelerra/filexml.C +++ b/cinelerra-5.1/cinelerra/filexml.C @@ -46,7 +46,7 @@ XMLBuffer::XMLBuffer(long buf_size, long max_size, int del) lmt = bfr + bsz; isz = max_size; destroy = del; - share_lock = new Mutex("XMLBuffer::share_lock"); + share_lock = new Mutex("XMLBuffer::share_lock", 1); } XMLBuffer::XMLBuffer(const char *buf, long buf_size, int del) diff --git a/cinelerra-5.1/plugins/sketcher/sketcher.C b/cinelerra-5.1/plugins/sketcher/sketcher.C index b9d729c9..a4ce51f9 100644 --- a/cinelerra-5.1/plugins/sketcher/sketcher.C +++ b/cinelerra-5.1/plugins/sketcher/sketcher.C @@ -495,8 +495,8 @@ static void smooth_sxy( if( fabsf(d) < 1 ) d = 1; sx = (acdx*bddx*by - acdx*bddx*cy + acdx*bddy*cx - acdy*bddx*bx) / d; sy = (acdx*bddy*by - acdy*bddx*cy - acdy*bddy*bx + acdy*bddy*cx) / d; - bclamp(sx, -32767.f, 32767.f); - bclamp(sy, -32767.f, 32767.f); + bclamp(sx, -4095.f, 4095.f); + bclamp(sy, -4095.f, 4095.f); } static void smooth_pxy( @@ -513,8 +513,8 @@ static void smooth_pxy( acdx*bx*cddy - acdx*by*cddx + acdx*cddx*cy - acdx*cddy*cx + 2*acdy*bx*cddx) / d; py = (abdx*acdy*by + abdx*acdy*cy - 2*abdy*acdx*by + abdy*acdy*bx - abdy*acdy*cx - 2*acdx*by*cddy + acdy*bx*cddy + acdy*by*cddx + acdy*cddx*cy - acdy*cddy*cx) / d; - bclamp(px, -32767.f, 32767.f); - bclamp(py, -32767.f, 32767.f); + bclamp(px, -4095.f, 4095.f); + bclamp(py, -4095.f, 4095.f); } static void smooth_qxy( float ax, float ay, float bx, float by, @@ -530,8 +530,8 @@ static void smooth_qxy( bddx*bx*cddy + bddx*by*cddx - bddx*cddx*cy - bddx*cddy*cx + 2*bddy*cddx*cx) / d; qy = (abdx*bddy*by + abdx*bddy*cy - 2*abdy*bddx*cy - abdy*bddy*bx + abdy*bddy*cx - 2*bddx*cddy*cy - bddy*bx*cddy + bddy*by*cddx + bddy*cddx*cy + bddy*cddy*cx) / d; - bclamp(qx, -32767.f, 32767.f); - bclamp(qy, -32767.f, 32767.f); + bclamp(qx, -4095.f, 4095.f); + bclamp(qy, -4095.f, 4095.f); }