Picker Image Portability
What a relative image path means
For a picker file, an image with a relative path means the image file is right beside the
.mgpkrfile.For a picker node, an image with a relative path means the image file is inside the Maya scene
directory / pickerimagesfolder.If the picker node is referenced in the Maya scene, the image of relative path means the image file is inside the
referenced source Maya scene directory / pickerimagesfolder.
Image Relative Path vs Absolute Path
Before
MG-Picker Studio 2.8, when you pick an image or import from an SVG file, it will trigger the image localisation; the image will be copied to the relevant directory, and a relative path will be used.Starting from
MG-Picker Studio 2.8, no image will be copied, and an absolute path will always be used when you pick/import an image, and by default, automatic image localisation only happens during these events:When you save/export the picker file/node. This behavior is a configuration that can be turned on/off.
When you save as a template file, the image localisation will always happen automatically regardless of the configuration.
In any image path editor that shows you the absolute image path, click on the down arrow and select
Localise this Image.Go to the
Imagesmenu in designer mode, selectProcess Images to Relative Path...
Starting from
MG-Picker Studio 2.8, the configuration of this auto-localisation during save/export can be turned on/off in two places:Go to the preferences dialog, in designer settings, in
Image Localisation, turn onCopy and Use Relative Paths on Save/Export.Go to the
Imagesmenu in designer mode, turn on/offAuto-Process Images to Relative Path on Save/Export.
Turning off
Image Localisationconfig, does not mean there won’t be any image copying during picker file/node save/export. It just means those items using absolute image paths will remain absolute, but those already using relative images paths, will still get their image copied to the new dir, otherwise those images won’t be recognized in the resaved picker.
Some other notes on images
💡 Starting from
2.8, when you save as a picker file/node, the popup UI will contain extra text at the bottom, to remind you if the image localisation will happen or not.
💡 Starting from
2.8, if you use thempg.MGPickerViewapi to save/export a picker file/node, you can specify an extra flagautoLocaliseImages=booleanto specify whether we do the image localisation during the save/export process. This flag is only used for this save/export process and will not impact your user configuration.
💡
V1takes an SVG vector image as a bitmap. Starting in V2, it will render SVG as a vector image.