[Scilab-users] converting octave script imremap to scilab
P M
p.muehlmann at gmail.com
Sun Nov 22 22:48:29 CET 2020
if you refer to interp2 from CGLAB toolbox....then no, I have no success
with that.
CGLAB call:
vp = interp2(xp,yp,x,y,v)...were xp and yp are vectors
while at octave:
warped = grayinterp(im, XI, YI, interp, NA); // im seems to be a mxn matrix
with:function [warped, valid] = grayinterp(im, XI, YI, interp,
extrapval) if (strcmp(interp, "cubic"))
warped = graybicubic(double(im), XI, YI, NA);
else
*warped = interp2(double(im), XI, YI, interp, NA);*
endif
valid = !isna(warped);
warped(!valid) = extrapval;endfunction
BR
Philipp
Am So., 22. Nov. 2020 um 08:55 Uhr schrieb Stéphane Mottelet <
stephane.mottelet at utc.fr>:
> Hi,
>
> Does interp2 works by using the triangulation ?
>
> S.
>
> Le 21 nov. 2020 à 22:56, P M <p.muehlmann at gmail.com> a écrit :
>
>
> Dear All,
>
> I am trying to map an image onto a 3D surface.
> The image contains reference points, which with known 2D pixel coordinates.
> The 3D equivalent of these reference points is as well known.
> The 3D shape is represented by a set of X-Y-Z coordinates.
>
> For mapping the image onto a delaunay-triangulated surface I found
> following function:
>
> "imremap"...which - as far as I understand - should do what I want.
>
> now: "imremap" uses "interp2"...and unfortunately both functions are in
> octave.
>
>
> imremap: https://searchcode.com/codesearch/view/9585363/
> <https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/searchcode.com/codesearch/view/9585363/>
>
> interp2: https://searchcode.com/codesearch/view/20327397/
> <https://antispam.utc.fr/proxy/2/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/searchcode.com/codesearch/view/20327397/>
>
>
> Converting the functions to Scilab seems to become an elephant, especially
> for interp2.
>
> If one could avoid "interp2" , then "imremap" could be possible
> relatively easy converted to Scilab.
>
> Any ideas which Scilab function would work like interp2?
>
> Thank you,
> Philipp
> _______________________________________________
> users mailing list
> users at lists.scilab.org
>
> https://antispam.utc.fr/proxy/1/c3RlcGhhbmUubW90dGVsZXRAdXRjLmZy/lists.scilab.org/mailman/listinfo/users
>
> _______________________________________________
> users mailing list
> users at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20201122/30208892/attachment.htm>
More information about the users
mailing list