POV-Ray : Newsgroups : povray.unofficial.patches : Bitwise functions Server Time
19 Jul 2024 10:49:24 EDT (-0400)
  Bitwise functions (Message 1 to 1 of 1)  
From: Le Forgeron
Subject: Bitwise functions
Date: 14 Jul 2010 14:48:37
Message: <4c3e0685@news.povray.org>
Purpose: being able to compute bitwise and, or & xor.

Apply to 3.7beta38



(see max() syntax)

Why: because I needed a XOR operation for placement (classical double
loop with xor:
 for i=1 to 2^n
 for j=1 to 2^n
   x = i;
   y = bitwise_xor(i,j);
  object at <x,y>
 end for j
 end for i

The <x,y> cover first the main diagonal of the square and will end with
the other diagonal.)

Post a reply to this message

Download 'bitwise.tar.gz' (24 KB)

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