Thread Tools Display Modes
Prev Previous Post   Next Post Next
10-17-17, 05:51 AM   #1
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 358
Why does a mask object automatically flip an art horizontally?

Hi all,

Just for testing, I have made a parallelogram texture and applied this on a plain texture object as well as on a texture object with a mask object.

The first one draws an art as it is while the second one automatically flips an art horizontally...



Here's an exact code snippet:

Lua Code:
  1. local mask = UIParent:CreateMaskTexture();
  2. mask:SetTexture(parallel);
  3. mask:SetSize(256, 32);
  4. mask:SetPoint("RIGHT", UIParent, "CENTER", -50, 0);
  5.  
  6. local texture1 = UIParent:CreateTexture(nil, "ARTWORK");
  7. texture1:SetColorTexture(1, 1, 1);
  8. texture1:SetAllPoints(mask);
  9. texture1:AddMaskTexture(mask);
  10.  
  11. local texture2 = UIParent:CreateTexture(nil, "ARTWORK");
  12. texture2:SetTexture(parallel);
  13. texture2:SetSize(256, 32);
  14. texture2:SetPoint("LEFT", UIParent, "CENTER", 50, 0);

Is this an intended behavior of a mask object?

Thank you!
  Reply With Quote
 

WoWInterface » Developer Discussions » Lua/XML Help » Why does a mask object automatically flip an art horizontally?


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off