示例#1
0
 /**
  * initializing from cached tables(move table, pruning table, etc.)
  *
  * @param in
  *     Where to read tables.
  *
  * @see cs.min2phase.Tools#saveTo(java.io.DataOutput)
  */
 public static void initFrom(System.IO.BinaryReader input)
 {
     if (Search.inited)
     {
         return;
     }
     CubieCube.initMove();
     CubieCube.initSym();
     read(CubieCube.FlipS2R, input);
     read(CubieCube.TwistS2R, input);
     read(CubieCube.EPermS2R, input);
     read(CubieCube.MtoEPerm, input);
     read(CubieCube.Perm2Comb, input);
     read(CoordCube.TwistMove, input);
     read(CoordCube.FlipMove, input);
     read(CoordCube.UDSliceMove, input);
     read(CoordCube.UDSliceConj, input);
     read(CoordCube.CPermMove, input);
     read(CoordCube.EPermMove, input);
     read(CoordCube.MPermMove, input);
     read(CoordCube.MPermConj, input);
     read(CoordCube.CCombMove, input);
     read(CoordCube.CCombConj, input);
     read(CoordCube.MCPermPrun, input);
     read(CoordCube.MEPermPrun, input);
     read(CoordCube.EPermCCombPrun, input);
     if (Search.EXTRA_PRUN_LEVEL > 0)
     {
         read(CubieCube.UDSliceFlipS2R, input);
         read(CubieCube.TwistS2RF, input);
         read(CoordCubeHuge.TwistMoveF, input);
         read(CoordCubeHuge.TwistConj, input);
         read(CoordCubeHuge.UDSliceFlipMove, input);
         read(CubieCube.FlipSlice2UDSliceFlip, input);
         CoordCubeHuge.initUDSliceFlipTwistPrun();
     }
     else
     {
         read(CoordCube.UDSliceTwistPrun, input);
         read(CoordCube.UDSliceFlipPrun, input);
         if (Search.USE_TWIST_FLIP_PRUN)
         {
             read(CubieCube.FlipS2RF, input);
             read(CoordCube.TwistFlipPrun, input);
         }
     }
     Search.inited = true;
 }
示例#2
0
文件: Search.cs 项目: theosZA/CubeCam
        public static void init()
        {
            if (inited)
            {
                return;
            }
            CubieCube.initMove();
            CubieCube.initSym();

            if (EXTRA_PRUN_LEVEL > 0)
            {
                CoordCubeHuge.init();
            }
            else
            {
                CoordCube.init();
            }

            inited = true;
        }