• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

HTML5 Canvas -Move mask using JavaScript?

Engaged ,
Mar 30, 2022 Mar 30, 2022

Copy link to clipboard

Copied

I have two promitive oval shapes on a mask layer, 'mask_idn'.  How can I move that mask layer, or the shapes on that layer,  using JavaScript?  I can't seem to assign instance name to the shapes...

Views

109

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Engaged , Mar 30, 2022 Mar 30, 2022

Got it working with:

mask.x -= 1;

 

Which is the variable for the mask in the JS file.

Votes

Translate

Translate
Engaged ,
Mar 30, 2022 Mar 30, 2022

Copy link to clipboard

Copied

LATEST

Got it working with:

mask.x -= 1;

 

Which is the variable for the mask in the JS file.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines