API calls for Photoworks.

Discussion in 'SolidWorks' started by Corey Scheich, May 24, 2004.

  1. Where the heck are they documented. I want to modify a material setting. I
    am trying to adjust the the transparency of a part using the a macro feature
    instead of using animator. I can't seem to get both the ability to fade in
    a part and have it maintain mirror properties. It seems that if the mirror
    levels are set above zero the part never fully disapears. Other suggestions
    are welcomed but I sure would like to know what calls are available.

    Corey Scheich
     
    Corey Scheich, May 24, 2004
    #1
  2. I thought the setting "Record actions to macro files" would record some API
    calls,
    however the only one that worked was...

    result = swApp.CallBack("pworks@MiEval", 0, "Render")

    It recorded this when I hit 'Render'. Render to file records something as
    well.

    Sorry I couldn't find what you needed. I would be interested in the answer
    as
    well!

    Mike Wilson
     
    Mike J. Wilson, May 25, 2004
    #2
  3. Great Mike if you don't know it I don't know who will. :^( Documentation
    would be nice. They have it for all the Addins I don't need but the 2 I
    would love to have and that would save the most time nothing (PhotoWorks and
    Animator.)

    Corey
     
    Corey Scheich, May 25, 2004
    #3
  4. Are you enrolled in the 2005 beta program? If you go to the forum,
    and to the API section, there is some more info there. I posted the
    question for you and it got answered, though it's depressing news.

    Mike Wilson
     
    Mike J. Wilson, May 25, 2004
    #4
  5. Unfortunately NO but that is as I expected maybe there will be some hope by
    the final release. I was hoping I could fade a chromic part in and out but
    I guess it will be another day or year, release anyway I put in an
    enhancement request if enough get in they may put some priority on it.

    Corey
     
    Corey Scheich, May 25, 2004
    #5
  6. actually, there are a couple calls that you can use. Unfortunately, most of
    the API is unavailable. All of the good stuff like picking materials,
    scenes, etc. if not open. I have found some success by setting up template
    files with the correct scene and just running the render using the following
    code:

    Dim FileNameParm As String = "RenderToFile Filename " & TargetDirectory &
    "\" & ActiveFile & ".bmp"



    result = swApp.CallBack("pworks@MiEval", 0, FileNameParm)

    result = swApp.CallBack("pworks@MiEval", 0, "RenderToFile Format bmp")

    result = swApp.CallBack("pworks@MiEval", 0, "RenderToFile Size 320 344")

    result = swApp.CallBack("pworks@MiEval", 0, "RenderToFile Render")

    This code will generate the file. The biggest problem with this method is
    that you cannot use a directory with a space in the name.

    There are some other commands you can use, but I have them in a document
    from SW corporate. Email me and I'll be glad to email it directly.
     
    Evan T. Basalik, May 26, 2004
    #6
  7. Corey,
    I really suggest that you download the beta. Registration is almost
    instant
    and you can download right away. The reason I say this is because, as you
    can imagine, the SolidWorks add-ins are always being improved in one way
    or another. I think you may find an easy answer to your problem.

    Unfortunately, I can't talk about it in public or they will have me killed
    ;^)

    Mike Wilson
     
    Mike J. Wilson, May 26, 2004
    #7
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.