Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

Quick Mask - using mask files


Zerren Gedeon
 Share

Recommended Posts

For anyone interested…

 

The addition of the new QuickMask commands in X2 is very nice, but…

What about QuickMask functionality that uses mask files?

 

Some of you may have never used the .mask files functionality in X.

Maybe you just don’t need this feature.

-or -

Maybe you found using mask files “not convenient enough” for you to realize their potential.

 

I present… 'Quick Mask File' for X2.

 

QuickMaskFile.ZIP is available on the Forum FTP site (in the X2_Add_Ons folder).

Just unzip the contents into your MCAMX2CHOOK folder and take a minute to read the DOC file...

Then you’ll be off to using Mask Files like you always imagined they could be. wink.gif

 

Any and all feedback is welcome!

Link to comment
Share on other sites

Sounds like Colin is a MASK file user! biggrin.gif

You do realize that you can fire off MASK files directly from the Quick Mask Manager.

 

When designing the Quick Mask Manager I did think about the ability to have multiple ‘one button’ masks. I thought that may be a lot of work for – “How many users would use this?” The thought of a ScriptLinker type solution did not come to mind.

An interesting idea and certainly possible to do.

 

But the question that remains is - How many users will use this?

If I hear enough “YES!” feedback I can investigate further.

Link to comment
Share on other sites

Colin,

 

I'll look into this, but...

NO promises are implied by that statement.

 

By Roger's and MasterShake's comments on the Developer forum I see that using CodeDOM in .NET is the way to go. I'm sure I can figure that out, but that is not the real issue here. What QuickMaskFile has to do to handle the mouse right-click is. Having to deal with a unknown number of toolbar buttons for one Chook DLL isn't too bad, but juggling multiple (and an unknown number of!) QuickMaskFile command DLLs may prove to be a real pain.

Link to comment
Share on other sites
  • 8 months later...

Hello all,

 

I've been away for awhile doing "other" things.

-----------------------------------------------

 

Colin (and others),

 

You asked for QuickMaskFile functionality like ScriptLinker.

The ability to create and assign a Mask file to a toolbar icon and/or keystroke. More that just the one the current QuickMaskFile allows for.

You’ll note my post on 10-30-2006 moaning about what a pain this would to do.

And it would have been (I tried!) prior to now.

I submitted a couple requests to CNC and they’ve implemented 2 features in the NETHook and CHook APIs (in X2-MR2) that now makes this project reasonable to do.

 

New API features smile.gif ->

1> The ability for Mastercam to tell your add-on that the user right-mouse clicked on your button. (This was key!)

2> The ability to have your add-on “dynamically” supply a text string to be used as the TipString you see when you hover the mouse over a toolbar button.

 

Now with these new features and knowing that using functions in the (.NET) CodeDOM namespace is the way ScriptLinker does its thing, I could do something.

 

So, I have a question for all you Mastercam users...

Are you still interested ?

Link to comment
Share on other sites

Thanks for the feedback.

 

I just got a 'proof of concept' NEThook project working that "creates" a (NETHook) DLL that executes a specified MASK file in ALL or (right mouse click)ONLY mode. cool.gif

So we're half way there. Still lots of work to do hooking it up with an interface and tying into the original QMF Manager.

BTW, The original QuickMaskFile will also be reworked using this new API functionality (detect right mouse click activation) to eliminate the need of having the QuickMaskFile icon on a toolbar prior to starting Mastercam.

 

I'll be back once I have something for you...

Link to comment
Share on other sites

on your toolbar there should be the filter options "All" and "only" these are your masks for selecting items. At the bottom of the mask page there is the option to save. These save your mask as a file.

Then you can use the chook from above.

Link to comment
Share on other sites

All,

 

We had enough #$&^#@! weather recently that allowed for more computer time. I don't know if that's a "good" thing or not! confused.gif

 

The result is... MaskFileLinker !

 

Notes:

#1> This only works with X2-MR2

(So you non-Beta users are going to have to wait awhile longer frown.gif ).

 

#2> The MaskFileLinker.dll requires that the QuickMaskFile.dll exists in the CHooks folder. (The QuickMaskFile.dll is the file that actually ‘reads’ the .Mask file).

The QuickMaskFile.dll (if you don’t have it) is available as part of the original QuickMaskFile.zip in the X2_add_ons folder of the forum FTP site, which is where you'll find the MaskFileLinker.ZIP that contains this new MaskFileLinker utility.

(A single DLL that goes into the CHook folder).

 

3> If the TipString is left blank’, the TipString (what you see when you hover over a toolbar icon) will be defaulted to the full pathname of the .MASK file that was “linked”.

 

Enjoy...

 

All feedback is appreciated.

No guarantee that I’ll be able to act on any suggestions, but I will listen. smile.gif

Link to comment
Share on other sites

Colin,

 

You're a bit too quick on the praise.

 

I realized last night that I'd missed setting a switch properly, so...

There is a new version of utility on the ftp site.

 

The original one always assumed that X2-MR2 was loaded in C:Mcamx2-MR2

 

This brings to light a topic for possible enhancement ->

Currently the full path/name of the .MASK file is stored in the DLL that is created. This means if X2-MR2 on your system is on C: and a co-worker's is on D:, you cannot just share the DLL & FT files created by MaskeFileLinker.

 

But, this setup would be desirable in this case ->

If you place the .MASK files in a common location on your network so that all your team can share the same .MASK files, now you do want the this full (static) path.

 

I was thinking of adding a "Relative Path" option checkbox. If checked, the DLL that gets built would always look the .MASK file "relative" the the 'base' folder of the active X2-MR2 session.

 

Any opinions?

 

zDog

Link to comment
Share on other sites
  • 9 months later...

Colin,

 

Just for you! biggrin.gif

 

On the forum FTP site in -- X3_Add_Ons is the package for X3.

 

It contains updated versions of->

*QuickMask Manager

*QuickMaskFile

*MaskFileLinker

 

A few notes....

1>

You can copy over your MaskLinked .DLL & .FT files from X2 over into the X3CHooks folder and the add-on will handle this "old" .MASK files.

*Of course the actual .MASK files being "run" must still be in the X2commonmasks folder.

(Recall the "Mask Linked" items have a hard-coded path to the .MASK file)

 

2>

The (X2) limitation of having to restart Mastercam after adding a quick mask item to a toolbar - has been eliminated.

 

3>

Right click (Only) mode now works, even if the quick mask item is placed on the right-mouse (RMB) menu.

 

*I have no idea this version of the add-on will work with X2-MR2 -> I assume that it will not, but I did not have time to test that.

If was getting late and this old dog needs his sleep wink.gif

 

If anyone wishes to try it using X2-MR2, do not be surprised if it does not work, or even *crashes* Mastercam. You have been warned! bonk.gif

 

Colin,

If this works and makes you (and your group) massively more productive, you can show your appreciation by sending a BBJ (you know what that is! think...think... headscratch.gif ) my way. cheers.gif

My needs are small, any configuration will do just fine! biggrin.gif

 

I anyone has any feedback and/or suggestions, I'll be happy to listen, but just an FYI - I will not be able to look at (or respond) to any inquires for a least several weeks.

 

[ 05-05-2008, 02:18 PM: Message edited by: Zerren Gedeon ]

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...