<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>I was able to get sliced scaling to work, using a different
SwsContext for each slice.</p>
<p>The problem is I can only use two slices, otherwise I run into
the 'Slices start in the middle!' error. The line of code that
detects that error is:</p>
<p>if (c->sliceDir == 0 && srcSliceY != 0 &&
srcSliceY + srcSliceH != c->srcH)</p>
<p>I'm not sure about sliceDir (I think it's about handling of
upside-down slices?) but basically either srcSliceY has to be 0
(meaning your slice starts from the very top of the source), or
srcSliceY plus srcSliceH has to be c->srcH (meaning your slice
ends at the very top of the source).</p>
<p>Is that 2 slice limit a known and expected limitation?<br>
</p>
<br>
<div class="moz-cite-prefix">On 9/18/2017 8:09 PM, J Decker wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAA2GJqWOmdt4aDveF7Yuki=V8s4zgCq8yaJWgQYTGp-Oqst_FQ@mail.gmail.com">
<div dir="ltr">I would think you would want different SwsContexts
for each thread. Otherwise you'd set the parameters for the
first thread, and then the second thread would override those
parameters used in the structure.
<div><br>
</div>
<div><br>
</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Mon, Sep 18, 2017 at 10:19 AM,
Martin Belleau <span dir="ltr"><<a
href="mailto:mbelleau@capellasystems.net" target="_blank"
moz-do-not-send="true">mbelleau@capellasystems.net</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">I see that
sws_scale has srcSliceY and srcSliceH, which should allow to
perform scaling of different slices in parallel.<br>
<br>
Is there any sample code which demonstrates how to use it?<br>
<br>
Should the same SwsContext be used to scale all the slices?<br>
<br>
______________________________<wbr>_________________<br>
Libav-user mailing list<br>
<a href="mailto:Libav-user@ffmpeg.org" target="_blank"
moz-do-not-send="true">Libav-user@ffmpeg.org</a><br>
<a href="http://ffmpeg.org/mailman/listinfo/libav-user"
rel="noreferrer" target="_blank" moz-do-not-send="true">http://ffmpeg.org/mailman/list<wbr>info/libav-user</a><br>
</blockquote>
</div>
<br>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Libav-user mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Libav-user@ffmpeg.org">Libav-user@ffmpeg.org</a>
<a class="moz-txt-link-freetext" href="http://ffmpeg.org/mailman/listinfo/libav-user">http://ffmpeg.org/mailman/listinfo/libav-user</a>
</pre>
</blockquote>
<br>
</body>
</html>