MCPcopy Create free account
hub / github.com/Tencent/libpag / SetImageFillMode

Function SetImageFillMode

exporter/src/export/Marker.cpp:528–537  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

526}
527
528void SetImageFillMode(pag::PAGScaleMode mode, const AEGP_ItemH& itemHandle, pag::ID imageID) {
529 std::string keyString = GetKeyStringWithId("ImageFillMode", imageID);
530 if (mode == pag::PAGScaleMode::LetterBox) {
531 DeleteMarkerFromComposition(itemHandle, keyString);
532 return;
533 }
534 std::string modeString = modeToStringMap.at(mode);
535 nlohmann::json value = modeString;
536 AddMarkerToComposition(itemHandle, keyString, value);
537}
538
539void SetLayerEditable(bool isEditable, const AEGP_ItemH& itemHandle, pag::ID id) {
540 std::string keyString = GetKeyStringWithId("noReplace", id);

Callers 1

setScaleModeMethod · 0.85

Calls 3

GetKeyStringWithIdFunction · 0.85
AddMarkerToCompositionFunction · 0.85

Tested by

no test coverage detected