RE: LDInstruction
2021-12-13, 13:27 (This post was last modified: 2021-12-13, 16:22 by Stefan Frenz. Edit Reason: typo / clarification )
2021-12-13, 13:27 (This post was last modified: 2021-12-13, 16:22 by Stefan Frenz. Edit Reason: typo / clarification )
(2021-12-13, 10:02)Philippe Hurbain Wrote: ...still struggling to understand how to go from raw 603 model to your nice single page modified version...
All changes are LDraw comments (type 0 lines) with "!LDINSP INSTR" or "!LDINSP INSTRSC" prefix. Every option is enclosed in brackets like [key=value]. Ordering or position of the corresponding line inside the step is not relevant, meaning: you can place every option for a step everywhere between the STEP/ROTSTEP lines. For convenience, the InstructionHelper GUI always places parameter changes at the top of the step and always in the same order, arranging corresponding options per line (e.g. "rotX" and "rotY" and "rotZ" are in one line and "step/maxColumns" and "step/maxRows" are in another line).
All parameters can be set with the GUI. No keyword has to be remembered or typed in.
The following changes inside the official omr lead to the given example (downloadable here):
- The main file has some global settings. Those are tagged with "doc/" (for the whole document) or "scope/" (options for a specific part that is not a sub-part of the current mpd file).
- Each sub-model has container layout information (step/maxColumns=0 and step/maxRows=0 where "0" is the special value for "auto layout to fill page").
- The torso with arms and hands is added as submodel, otherwise those five parts would be listed as separate parts in the pli of step 6.
In more detail:
Code:
0 !LDINSP INSTR [doc/dpi=150] [doc/width=29700] [doc/height=21000] [doc/margin=1000]
0 !LDINSP INSTR [doc/bgModel=CFEFFF] [doc/bgPli=BFDFFF] [doc/bgSub=FFF0CF]
Second line: define background colors for model (light blue), part list inventory (darker light blue) and inlined sub-steps (light yellow).
Code:
0 !LDINSP INSTRSC [scope=3626ap01.dat] [pli/rotX=15] [pli/rotY=0]
0 !LDINSP INSTRSC [scope=3641.dat] [pli/rotY=45]
Code:
0 !LDINSP INSTR [zoom=2]
0 !LDINSP INSTR [centerX=15.58] [centerY=-7.841] [centerZ=57.228]
0 !LDINSP INSTR [rotX=30] [rotY=45] [rotZ=0]
0 !LDINSP INSTR [step/noPli=1]
0 !LDINSP INSTR [step/modelX=-2] [step/modelY=-1]
0 !LDINSP INSTR [step/maxColumns=0] [step/maxRows=0]
- step/noPli: if set to 1, the step will have no part list inventory (default 0 means "show pli")
- step/modelX=-2 and step/modelY=-1: place the model horizontally right aligned and vertically centered (0..n is fixed offset, -1 means "center", -2 means "right"/"bottom")
- step/maxColumns=0 and step/maxRows=0: either give a positive number as maximum cols/rows per page, or (indepently) value 0 means "auto".
The sidecar sub-file has
Code:
0 !LDINSP INSTR [step/modelX=-2] [step/modelY=-1]
0 !LDINSP INSTR [step/maxColumns=0] [step/maxRows=0]
0 !LDINSP INSTR [inl/zoom=1.5]
The wheel sub-file has
Code:
0 !LDINSP INSTR [inline]
0 !LDINSP INSTR [step/modelX=-2] [step/modelY=-1]
0 !LDINSP INSTR [step/maxColumns=0] [step/maxRows=0]
The added body sub-file has another sub-file flag
Code:
0 !LDINSP INSTR [aspart]