Painting product

Support.vcmx (3.4 MB)

Hello,

I want to paint product which is fed by extarnal (gantry ) system. When you open the project i have sent, you will see product is changed color immediately, not step by step. Also after spin stop,color is return first situation with all the same product are changed at the same time.

Does anyone has an idea ?

Hy,

if I run your simulation I get this Error:

Error

Regards
Feature

Do you have the Premium Version? The Professional Version does not support the painting API.
After I checked for None, I get following message:

RuntimeError: No license for 3D Topology

Checking for None beginning with line 208:

      pts = geoset.getPointIndexesWithin(nP, testSphereR)
      if pts is None:
        print "pts is None at index", i
        continue
      total += len(pts)

This won’t fix the issue, it’s just a workaround.
I guess the error is somewhere else, but I can’t help here.

1 Like

No I havn’t… I thought it was about the painting feature from Premium…

I also have no experience with it!

hi,

I m using premium 4.2 version. Also when i run the similation, i didnt take any issues. I don’t know where is problem…

No Premium, no painting.

If no one in forum can help, try to contact support…

Regards
Feature

If you want to paint dynamic components,

  1. You need to prepare the part for painting
  2. Make the created part unique. In this layout, PaintDynamicComponents.vcmx (1.3 MB) check the python script in Basic feeder component

hi popeye,

Could you check that similation different.vcmx (1.2 MB) . what is the difference of component between yours and mine

I think the issue is the geometry of your component. For example, the topology and faces of the geometry have issues with some being inverted. This is something a cleaning or analysis tool in the native CAD editor should detect and fix with the model prior to import. I checked with different model and tried cleaning your component in Visual Components best I could, but how and where the paint is to be applied is probably unknown to the paint gun since the bottom of the part and top seem to have face plane intersection and several seem to have surface normal issues.

1 Like

hello,my VC version is 4.6,but I find that the demo you offered can’t run correctly,it seems that the method “makeUnique()” in component is deprecated.
Damn it!

I just did a quick test with a feeder and a conveyor, and the makeUnique method seems to be working fine.

from vcScript import *

def transition_handler(part, arrive):
  if arrive:
    part.makeUnique()

comp = getComponent()
path = comp.findBehaviour("Path__HIDE__")
path.OnTransition = transition_handler

OK,I will try it again,thx!

@Este Unfortunately,I have reinstalled WIN10 OS(22H2) and VC4.6,but it can’t work.
Is it a bug?I hope it could be corrected in future version…


Why can’t it take effect?It’s so confusing!
@Este @WilliamSmith

not for your product type editor, you should create the code from este in a python script in your feeder, did you test that?

I had test it,but it failed

I think I may have to retire this zesty account. Yawl making me time travel 3 years, and I don’t even believe space-time exists.

Anyway, take this layout and test it.
PaintDynamicComponents.vcmx (1.1 MB)

I modified the @Popeye layout in VC 4.7. Check the script in the Feeder. A couple things worth mentioning. First, in process modeling the product creator has an event for when a product is created. From there, I used a workaround made by @jouha so the dynamic components don’t act like turd burglars when paint is applied and you rerun the simulation.

Does it do the job @killyouz ?
Flexing Hulk Hogan GIF by WWE

1 Like

OK,it runs correctly
Thx!