diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2024-06-16 10:58:54 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2024-06-16 10:58:54 +0200 |
| commit | 02ce9adf6a9168ec66c322ce9e5a5cb9fe1e60a5 (patch) | |
| tree | d3385b1a1c915a74c373434032f0fe26e843854f /src/cube.h | |
| parent | c04a283a7ab97903683f5f7268068aef69f5bddf (diff) | |
| download | nissy-core-02ce9adf6a9168ec66c322ce9e5a5cb9fe1e60a5.tar.gz nissy-core-02ce9adf6a9168ec66c322ce9e5a5cb9fe1e60a5.zip | |
Added rudimentary shell to run commands (ugly)
Diffstat (limited to 'src/cube.h')
| -rw-r--r-- | src/cube.h | 24 |
1 files changed, 12 insertions, 12 deletions
| @@ -4,47 +4,47 @@ number in case of error, unless otherwise specified. See (TODO: | |||
| 4 | documentation) for details. | 4 | documentation) for details. |
| 5 | */ | 5 | */ |
| 6 | 6 | ||
| 7 | int nissy_compose( | 7 | int64_t nissy_compose( |
| 8 | const char cube[static 22], | 8 | const char cube[static 22], |
| 9 | const char permutation[static 22], | 9 | const char permutation[static 22], |
| 10 | char result[static 22] | 10 | char result[static 22] |
| 11 | ); | 11 | ); |
| 12 | 12 | ||
| 13 | int nissy_inverse( | 13 | int64_t nissy_inverse( |
| 14 | const char cube[static 22], | 14 | const char cube[static 22], |
| 15 | char result[static 22] | 15 | char result[static 22] |
| 16 | ); | 16 | ); |
| 17 | 17 | ||
| 18 | int nissy_applyoves( | 18 | int64_t nissy_applymoves( |
| 19 | const char cube[static 22], | 19 | const char cube[static 22], |
| 20 | const char *moves, | 20 | const char *moves, |
| 21 | char result[static 22] | 21 | char result[static 22] |
| 22 | ); | 22 | ); |
| 23 | 23 | ||
| 24 | int nissy_applytrans( | 24 | int64_t nissy_applytrans( |
| 25 | const char cube[static 22], | 25 | const char cube[static 22], |
| 26 | const char *transformation, | 26 | const char *transformation, |
| 27 | char result[static 22] | 27 | char result[static 22] |
| 28 | ); | 28 | ); |
| 29 | 29 | ||
| 30 | int nissy_frommoves( | 30 | int64_t nissy_frommoves( |
| 31 | const char *moves, | 31 | const char *moves, |
| 32 | char result[static 22] | 32 | char result[static 22] |
| 33 | ); | 33 | ); |
| 34 | 34 | ||
| 35 | int nissy_readcube( | 35 | int64_t nissy_readcube( |
| 36 | const char *format, | 36 | const char *format, |
| 37 | const char *cube_string, | 37 | const char *cube_string, |
| 38 | char result[static 22] | 38 | char result[static 22] |
| 39 | ); | 39 | ); |
| 40 | 40 | ||
| 41 | int nissy_writecube( | 41 | int64_t nissy_writecube( |
| 42 | const char *format, | 42 | const char *format, |
| 43 | const char cube[static 22], | 43 | const char cube[static 22], |
| 44 | char *result | 44 | char *result |
| 45 | ); | 45 | ); |
| 46 | 46 | ||
| 47 | int nissy_convertcube( | 47 | int64_t nissy_convertcube( |
| 48 | const char *format_in, | 48 | const char *format_in, |
| 49 | const char *format_out, | 49 | const char *format_out, |
| 50 | const char *cube_string, | 50 | const char *cube_string, |
| @@ -58,13 +58,13 @@ slightly larger than the actual table size. | |||
| 58 | */ | 58 | */ |
| 59 | int64_t nissy_datasize( | 59 | int64_t nissy_datasize( |
| 60 | const char *solver, | 60 | const char *solver, |
| 61 | const char *options | 61 | const char *options /* TODO: remove options, use only solver name */ |
| 62 | ); | 62 | ); |
| 63 | 63 | ||
| 64 | /* Returns the number of bytes written, or -1 in case of error */ | 64 | /* Returns the number of bytes written, or -1 in case of error */ |
| 65 | int64_t nissy_gendata( | 65 | int64_t nissy_gendata( |
| 66 | const char *solver, | 66 | const char *solver, |
| 67 | const char *options, | 67 | const char *options, /* TODO: remove options, use only solver name */ |
| 68 | void *generated_data | 68 | void *generated_data |
| 69 | ); | 69 | ); |
| 70 | 70 | ||
| @@ -72,8 +72,8 @@ int64_t nissy_gendata( | |||
| 72 | int64_t nissy_solve( | 72 | int64_t nissy_solve( |
| 73 | const char cube[static 22], | 73 | const char cube[static 22], |
| 74 | const char *solver, | 74 | const char *solver, |
| 75 | const char *options, | 75 | const char *options, /* TODO: remove options, use only solver name */ |
| 76 | const char *nisstype, | 76 | const char *nisstype, /* TODO: remove, use flags */ |
| 77 | int8_t minmoves, | 77 | int8_t minmoves, |
| 78 | int8_t maxmoves, | 78 | int8_t maxmoves, |
| 79 | int64_t maxsolutions, | 79 | int64_t maxsolutions, |
