POV-Ray : Newsgroups : povray.unofficial.patches : yuqk feature requests / suggestions : Re: yuqk feature requests / suggestions Server Time
2 Jun 2024 15:22:04 EDT (-0400)
  Re: yuqk feature requests / suggestions  
From: William F Pokorny
Date: 11 Jan 2024 20:41:35
Message: <65a098cf$1@news.povray.org>
On 1/11/24 19:02, Bald Eagle wrote:
> So, I'd be able to just plop a decimal argument in, and use binary functions on
> it?
> Simple code example?

#version unofficial 3.8; // yuqk
#if (file_exists("version.inc"))
     #include "version.inc"
#end
#if (!defined(Fork_yuqk))
     #error "This POV-Ray SDL code requires the yuqk fork."
#end

#include "functions.inc"
#declare FnXor = function (a,b) {
//  f_64x_ui1_toflt(  // For explicit conversion back to float
     f_64x_ui1_xor(
         f_64x_ui1_fltto(a),
         f_64x_ui1_fltto(b),
         4  // Internal conversion xor result back to a float
     )
//  )
}

#debug concat("xor(7,3) ",str(FnXor(7,3),3,0),"\n")

#error "Stopping after parse"

Note. Due the differences in double and unsigned long integers, values 
are limited to a zero to pow(2,53)-1 range where doubles are involved.

Bill P.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.