David Grzesik

FortifiedOatMilk

About Me

専門知識
VFX Artist
INDUSTRY
Advertising / Motion Graphics

Connect

LOCATION
Not Specified
ウェブサイト

Houdini Skills

Availability

Not Specified

Recent Forum Posts

Rendering Overlapping Visibility 2024年1月15日19:09


I came across an interesting problem when I was doing some RnD for some toon shaders and effects. I want to render effectively only the geometry that is overlapping from 2 different sources. It's sort of a visual boolean, but I don't want the costly geometry operations from calculating that every frame.
I can understand a way of compositing this effect, it would be simply multiplying the alpha of the two objects together, but that takes extra time to render/comp, would have to be done individually for each set of objects, and does not work with reflections. I'd love to get this effect working purely in render.


This is my general idea, for the blue object to be rendered at all, a ray has to pass through both the pink and blue objects. The pink object does not contribute to any shading color, that is all contributed by the blue object. In the case of this diagram, rays A, B, and C would render the blue object and rays D and E would simply pass right through as they hit only the pink or only the blue object.

Unfortunately my knowledge of Houdini is more in geometry manipulation/simulation and not materials and rendering so this task is a bit difficult for me and I'm having trouble finding out where to start. If anyone has any ideas on where to start for this, I would love to hear them!

PDG doesn't cook full network after a Server Block 2022年11月28日11:09

So I managed to find a work around for this behavior. Referencing this [www.sidefx.com] page on TOPs event handling, I put an event handler for when the "commandserverend" TOP completed cooking. This way immediately as that server block finishes, it will call to cook the output node at the bottom.
Here's the example snippet I placed in the OnCreated script on the HDA so the event is registered each time when the node is loaded in:
import pdg
top_node = kwargs['node'].node("./query_SG/commandserverend2")

top_node.cookWorkItems(tops_only=True)

pdg_context = top_node.getPDGGraphContext()

# Define our event handler
def cookRestOfNetwork(event):
    kwargs['node'].node("./query_SG/output0").cookWorkItems()
    
pdg_context.addEventHandler(cookRestOfNetwork, pdg.EventType.CookComplete)

This had a strange behavior in an earlier test where I was using the ui display message example from the TOPs Events page where everything would work as expected, but if I had it also cook that output node it would endlessly pop up the display message....So I just took that ui stuff out because of course its not needed and it didn't endlessly loop.

I don't know exactly what is up with this, but this seems to be working for the time being.

Would love to not have to do this though and just be able to cook the full graph as usual lol

PDG doesn't cook full network after a Server Block 2022年11月22日16:07

So I am using TOPs to query Shotgrid and return information about assets in this example. For some reason when cooking this network TOPs will only cook the Shotgrid server block and consider the graph done. If I then manually ask it to cook again, it will finish up the graph. This is a very strange behavior that I was hoping someone might have some insight into?


You can see that during the first cook the TOP net has the nodes below waiting for evaluation. But, as see in AfterCook1, these nodes are left uncompleted after the server block finishes cooking. When I force it to cook again, it quickly finishes up these nodes.


I am using the top level TOP net buttons to control the network and am using "Cook Output Node". Also the little warning on the server end block is simply an attribute incompatibility message.