SgfcKit is an Objective-C wrapper library around the C++ library libsgfc++, which in turn is a wrapper for SGFC, the SGF Syntax Checker & Converter. SgfcKit transitively inherits SGFC's core functionality from libsgfc++:
- Read and write SGF (Smart Game Format) files.
- Check the file content for correctness.
- Correct any errors.
- Convert FF[1] - FF[3] files to the FF[4] format.
SgfcKit is not restricted to files, it also reads and writes SGF data from/to NSString without filesystem interaction.
The SgfcKit API closely resembles the one offered by libsgfc++, but is re-modeled towards the idioms that prevail in the Objective-C world.
SgfcKit theoretically is cross-platform - as long as your desired platform has an Objective-C compiler and you are able to also build the underlying libsgfc++, you might be successful in building and running SgfcKit for/on that platform. In practice, though, SgfcKit is likely to be restricted to the macOS and iOS-derived platforms.
The limitations of SGFC also apply to SgfcKit. Quoting from the SGFC website:
SGFC is intended to be a tool for SGF experts, coders and maintainers of large SGF archives. You ought to have quite some knowledge of SGF to use SGFC efficiently.
SGFC was written primarily for Go/WeiQi/Baduk (GM[1]) files. It can't handle other games yet, i.e. it doesn't check any game-specific properties and values of other games than Go. It may even save erronous game-specific properties of other games! Use SGFC for other games with care.
At runtime SgfcKit only depends on libsgfc++, the C/C++/Objective-C runtime libraries and the C++ standard library.
At build time SgfcKit has the following dependencies:
- The main dependency, of course, is libsgfc++. To compile libsgfc++, a compiler is required that supports a relatively modern version of the C++ standard - see the top-level
CMakeLists.txtfile in the libsgfc++ project which version this is. - The second dependency is the build management tool CMake.
- A last dependency is Doxygen, used to optionally generate the project's API documentation.
Dependency 1 is integrated via Git submodule.
The project build system is documented here.
- Library design and working principles
- Bugs and limitations
- Coding guidelines
- If you have SGF-related questions you may find them answered in the document section of libsgfc++.
SgfcKit is released under the Apache License (2.0). Here's the link to the license file.
libsgfc++ is released under the terms of the Apache License (2.0).
- Link to local license file. This works only if you have a local clone of the SGFC git submodule.
- Link to remote license file. This link points to the
masterbranch version of the license file.
SGFC is released under the terms of the BSD License.
- Link to local license file. This works only if you have a local clone of the SGFC git submodule.
- Link to remote license file. This link points to the
masterbranch version of the license file.