mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-14 18:27:51 -06:00
Try to use Protobuf CPP implementation if it is available
The C++ implementation is far faster so should always be used if available. If not, we log a warning since it makes a big difference.
This commit is contained in:
parent
cb05aee391
commit
1140c853d1
2 changed files with 11 additions and 0 deletions
|
@ -134,6 +134,9 @@ class CuraApplication(QtApplication):
|
|||
parser.add_argument("--debug", dest="debug-mode", action="store_true", default=False, help="Enable detailed crash reports.")
|
||||
|
||||
def run(self):
|
||||
if not "PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION" in os.environ or os.environ["PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION"] != "cpp":
|
||||
Logger.log("w", "Using Python implementation of Protobuf, expect bad performance!")
|
||||
|
||||
self._i18n_catalog = i18nCatalog("cura");
|
||||
|
||||
i18nCatalog.setTagReplacements({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue