No matching overload found
Сергей Владимирович <[email protected]> Wed, 1 Apr 2015 14:22:37 +0300
| Newsgroups | gmane.comp.lang.lua.bind.user |
|---|---|
| Message-ID | <CAF4f3cNOmUrfaSNyb0uq8d9EdspEU1AVno=Bw_CQsLc10M0V-Q@mail.gmail.com> |
--===============5637224819162079661== Content-Type: multipart/alternative; boundary=90e6ba3fcb83bc228e0512a7ee9b --90e6ba3fcb83bc228e0512a7ee9b Content-Type: text/plain; charset=UTF-8 Why luabind can't use this function? C++ code: Vector3f createVector3f ( float x, float y, float z ); Lua Code: function UiControl:setScale ( value ) log ( "UiControl:setScale: " .. value ) local s = createVector3f ( value, value, 1 ) --error self.mesh:setScale ( s ) self.mesh:update () end Output: UiControl:setScale: 1 No matching overload found, candidates: Vector3f createVector3f(custom [f],custom [f],custom [f]) I know, this code works: local s = createVector3f ( 1, 1, 1 ) Why it doesn't when I pass an variable? Point me, please, where to dig. --90e6ba3fcb83bc228e0512a7ee9b Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>Why luabind can't use this function?</div><div><b= r></div><div>C++ code:</div><div>Vector3f createVector3f ( float x, float y= , float z );</div><div><br></div><div>Lua Code:</div><div>function UiContro= l:setScale ( value )</div><div><span class=3D"" style=3D"white-space:pre"> = </span>log ( "UiControl:setScale: " .. value )</div><div><span cl= ass=3D"" style=3D"white-space:pre"> </span>local s =3D createVector3f ( val= ue, value, 1 ) --error</div><div><span class=3D"" style=3D"white-space:pre"= > </span>self.mesh:setScale ( s )</div><div><span class=3D"" style=3D"white= -space:pre"> </span>self.mesh:update ()</div><div>end</div><div><br></div><= div>Output:</div><div>UiControl:setScale: 1</div><div>No matching overload = found, candidates:</div><div>Vector3f createVector3f(custom [f],custom [f],= custom [f])</div><div><br></div><div>I know, this code works:</div><div>loc= al s =3D createVector3f ( 1, 1, 1 )</div><div>Why it doesn't when I pas= s an variable?</div><div><br></div><div>Point me, please, where to dig.</di= v></div> --90e6ba3fcb83bc228e0512a7ee9b-- --===============5637224819162079661== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ --===============5637224819162079661== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ luabind-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/luabind-user --===============5637224819162079661==--