<p>Found a solution.
This need to be applied under <code>"settings"</code></p>

<pre><code>"command_line_settings": {
    "label": "Command Line Settings",
    "description": "Settings which are only used if CuraEngine isn't called from the Cura frontend.",
    "type": "category",
    "enabled": true,
    "children": {
        "center_object": {
        "description": "Whether to center the object on the middle of the build platform (0,0), instead of using the coordinate system in which the object was saved.",
            "type": "bool",
            "label": "Center object",
            "default_value": true,
            "enabled": true
        }
    }
}
</code></pre>

CC BY-SA 3.0
2017-10-26T15:10:33.797Z
2017-10-26T15:10:33.797Z
thedp
<p>If this is over the commandline tool "CuraEngine", then you will have to read the sourcecode. According to the <a href="https://ultimaker.com/en/community/4337-doc-of-curaengine" rel="nofollow noreferrer">Author</a>, 'Nope. Only documentation there is in the code, readme and my head.' (cringe!).</p>

<p>If you're talking of the GUI program, then right click and click "Center". But this requires GUI usage. Not so nice if you want to automate using curaengine as your slicer.</p>

CC BY-SA 3.0
2017-10-25T13:52:27.727Z
2017-10-25T13:52:27.727Z
joshConway
<p>How can I center a model at the middle of the printing area of the printer when creating a g-code with CuraEngine. </p>

<p>Are there any parameters I can add to <code>ultimaker2.def.json</code> to achieve this?
Thanks.</p>

<ultimaker-cura><g-code>
Centering model with CuraEngine when creating g-code?
thedp
# Centering model with CuraEngine when creating g-code?

(Asked by: username_0 on 2017-10-25)

How can I center a model at the middle of the printing area of the printer when creating a g-code with CuraEngine.

Are there any parameters I can add to `ultimaker2.def.json` to achieve this?
Thanks.

**Tags:** ultimaker-cura, g-code

---

## 2 answers

### Answer by username_0 on 2017-10-26. Score: 1 | Accepted answer

Found a solution.
This need to be applied under "settings"
"command_line_settings": {
    "label": "Command Line Settings",
    "description": "Settings which are only used if CuraEngine isn't called from the Cura frontend.",
    "type": "category",
    "enabled": true,
    "children": {
        "center_object": {
        "description": "Whether to center the object on the middle of the build platform (0,0), instead of using the coordinate system in which the object was saved.",
            "type": "bool",
            "label": "Center object",
            "default_value": true,
            "enabled": true
        }
    }
}


---

### Answer by username_1 on 2017-10-25. Score: -3

If this is over the commandline tool "CuraEngine", then you will have to read the sourcecode. According to the [Author](https://ultimaker.com/en/community/4337-doc-of-curaengine), 'Nope. Only documentation there is in the code, readme and my head.' (cringe!).

If you're talking of the GUI program, then right click and click "Center". But this requires GUI usage. Not so nice if you want to automate using curaengine as your slicer.


---

