Jump to content

  • Log In with Google      Sign In   
  • Create Account


#Actualferrous

Posted 04 June 2014 - 02:59 PM

Can you just flatten the array?  Then you basically have a bitfield or an integer, and just compare the integers.  EDIT:  Whoops, that doesn't count mirrored versions.  Though you could compute that as well, I think, by flipping those sections in integer. and testing for equality.

 

EDIT2:  For rotation, I think you might be able to get away by rotating the bitfield.  IE 10010010, rotated right by 1 is 01001001.  Might be worthwhile.

 

EDIT3:  Are mirrors a derivative of rotations?  They are at least in the 2D cube case.  In which case, I believe you basically just loop and rotate one of the bitfields through 8 times to see if it matches the other?  


#3ferrous

Posted 04 June 2014 - 02:44 PM

Can you just flatten the array?  Then you basically have a bitfield or an integer, and just compare the integers.  EDIT:  Whoops, that doesn't count mirrored versions.  Though you could compute that as well, I think, by flipping those sections in integer. and testing for equality.

 

EDIT2:  For rotation, I think you might be able to get away by rotating the bitfield.  IE 10010010, rotated right by 1 is 01001001.  Might be worthwhile.


#2ferrous

Posted 04 June 2014 - 02:37 PM

Can you just flatten the array?  Then you basically have a bitfield or an integer, and just compare the integers.  EDIT:  Whoops, that doesn't count mirrored versions.  Though you could compute that as well, I think, by flipping those sections in integer. and testing for equality.


#1ferrous

Posted 04 June 2014 - 02:35 PM

Can you just flatten the array?  Then you basically have a bitfield or an integer, and just compare the integers.


PARTNERS