Jump to content

Search the Community

Showing results for tags 'primitve hook'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Lounge/General chat
    • Education
    • Jobs
    • Marketplace
  • Houdini
    • General Houdini Questions
    • Effects
    • Modeling
    • Animation & Rigging
    • Lighting & Rendering + Solaris!
    • Compositing
    • Games
    • Tools (HDA's etc.)
  • Coders Corner
    • HDK : Houdini Development Kit
    • Scripting
    • Shaders
  • Art and Challenges
    • Finished Work
    • Work in Progress
    • VFX Challenge
    • Effects Challenge Archive
  • Systems and Other Applications
    • Other 3d Packages
    • Operating Systems
    • Hardware
    • Pipeline
  • od|force
    • Feedback, Suggestions, Bugs

Product Groups

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Skype


Name


Location


Interests

Found 1 result

  1. Looking at the sample GUI_PolygonNormalShade, I'm trying to replace the material in the viewport when a visualizer is set. I have been trying to do this by copying the approach used in GUI_PolygonNormalShade but instead of writing new "Cd" attributes I want to write a new "shop_materialpath" attribute to the detail attributes. Its look like everything is correct (no crashes or errors) but I'm still not getting the new material to show in the viewport. Any ideas would be super helpful. Here is the code from the filterPrimitive function. processed = GR_PROCESSED; char arr[] = "/mat/test"; OP_Node* matNode = OPgetDirector()->findNode(arr); if (!matNode) { OP_Network *parent = (OP_Network *)OPgetDirector()->findNode("/mat"); parent->createNode("tooncolorshader", "test"); matNode = OPgetDirector()->findNode(arr); } string path(arr); auto indexedString = new GT_DAIndexedString(1); indexedString->setString(0, 0, path.c_str()); GT_AttributeListHandle dah = gt_prm->getDetailAttributes()->addAttribute("shop_materialpath", indexedString, true); auto mesh = UTverify_cast<const GT_PrimPolygonMesh *>(gt_prm.get()); ph = new GT_PrimPolygonMesh(*mesh, mesh->getPointAttributes(), mesh->getVertexAttributes(), mesh->getUniformAttributes(), dah); // return a new polygon mesh with modified shop_materialpath attribute. return ph;
×
×
  • Create New...