Jump to content

Leaderboard


Popular Content

Showing most liked content on 07/24/2019 in all areas

  1. 3 points
  2. 2 points
    Procedurally generated cyberpunk building I've done this project before one year ,I draw a simple concept then I try to develop a complete procedural system inside houdini , it was fun experience Hope You Like it vimeo link : https://vimeo.com/349515288 behance: https://www.behance.net/gallery/83268643/Procedural-Cyberpunk-Building
  3. 2 points
    found a great video on vimeo what a freak.... ;-)
  4. 2 points
    This is a script coded by a friend : https://berniebernie.fr/wiki/Houdini_Python I think it would be great to have something like this by default on Houdini, in order to get a previz image of a certain part of the node graph. It could be very useful when sharing setup between people for complex FX / Rigs / Lighting setup.
  5. 1 point
    You could start with pre built elements, walls, windows, chimney, doors and integrate those into your procedural setup. Personally I would take that a step further and use those geometries only as a template and rebuild them in Houdini and give myself a clean slate to better build it procedurally.
  6. 1 point
    Ah, yes I could see how that could be difficult to understand. The foreach loop is running on each named piece, that is the pieces that separate when we use a exploded view SOP. Look in the spreadsheet under the primitive attribute "name". All of those with the same name are processed together at once. The loop merges each iteration with the gather method. This means that all the outputs are put together at the end instead of just the last one. Inside that loop is a single switch. That switch asks (with the nprimsgroup function) if there are any primitives in the group called "outside". If there are at least one then that currently processed piece is swapped for the null. That "-1" and the spare Input 0 is really weird to me. I would just use opinputpath(".",0), but I can see how that would be a little less procedural. The compile block just makes the whole thing run faster and for demonstration purposes so we can ignore it here. But it is necessary if we're actually dealing with a lot of geometry, and shattered objects can get really big.
  7. 1 point
    SideFX it's time to to show some love for COPs . It would be nice to have fixed the instability and the slowness of COPs, and also have some nice low level tools. COPs could easily compete with Substance Designer for procedural texture creation, especially when Allegortmic is not caring at all about their substance plugin for Houdini. There's opportunity here. Also, it would much welcome to have better parameters UI. There are lots small improvements to do in this regard: like being able to decide how to justify the parameters, unified alignment, better labeling systems, etc I want the controls of my Digital Assets to feel modern and to be space-efficient.
  8. 1 point
    Yeah in that case you need to declare @ptnum at the top. So: int @ptnum; int id = point(0,"id",@ptnum); setpointattrib(0,"Cd", @ptnum,id); Think of it as a key. If you write @ptnum further down, it will take a look to see if it's allowed to accept that. If it isn't declared, or if you make a typo (@ptnmu) it will error because it isn't allowed. I don't think you can get rid of @ altogether, but you can add it to a variable to get rid of it further down: int @ptnum; int pointnum = @ptnum;
  9. 1 point
    you can try with pcnumfound(), have a look: point_density_bunker_001.hipnc
  10. 1 point
    don't have H17 at hand but since volumeRasterizeAttribute uses volumeRasterizeParticles internally and at least in H16.5 volumeRasterizeParticles has those intrinsics I don't know why they shouldn't be available to you. I don't think SideFX removed them in 17, need to check later though edit: in any case, this is Houdini so there's a million way to do things. How about convert your volume (to SDF) to polygons, measure area, sum up area -> get some value that way
  11. 1 point
    I don't know if it is of any use but here is a linux version... DISCLAIMER, I have ignored accounting for the outputConnections() as I don't really understand the purpose... also I have commented a bit further and expand strings to support variables vs absolute paths discrepancies... should work ok. import hou import os import subprocess import nodegraphutils as utils from time import gmtime, strftime widthRatio = 4 # change to make screenshot bigger or smaller, this is ~x4 node width # -------------------------------------------------------------------------------------------- # FUNCTIONS # -------------------------------------------------------------------------------------------- def createScreenshotFolder(saveFolder): '''create screenshot folder under $HIP folder ''' # System call to create the necessary folder subprocess.check_call([r"mkdir", r"-p", saveFolder]) def takeScreenShot(savePath): '''change to your preferred capture app /!\ no error checking for now ''' # System call using ImageMagik import command that requests an interactive region to operate subprocess.check_call([r"import", savePath]) def removeBackgroundImage(**kwargs): ''' erases bg image from tuples of backgroundImages() if it can find it, updates bg ''' # find the node that is meant to be deleted deletingNode = [x[1] for x in kwargs.items()][0] # find the image in the spare tab image = deletingNode.parm('houdinipath').eval() # find the network editor = hou.ui.paneTabOfType(hou.paneTabType.NetworkEditor) # collect the images stored in it backgroundImagesDic = editor.backgroundImages() # find the one image to be deleted backgroundImagesDic = tuple(x for x in backgroundImagesDic if hou.expandString(x.path()) != hou.expandString(image)) # update the images editor.setBackgroundImages(backgroundImagesDic) utils.saveBackgroundImages(editor.pwd(), backgroundImagesDic) def changeBackgroundImageBrightness(event_type,**kwargs): ''' changes brightness/visibility if template or bypass flags are checked -- its poorly written/thought but i was tired''' # find the null holding the image nullNode = [x[1] for x in kwargs.items()][0] # find the image in the spare tab image = nullNode.parm('houdinipath').eval() # define color based on flags if nullNode.isBypassed(): brightness = 0.0 elif nullNode.isTemplateFlagSet(): brightness = 0.5 else: brightness = 1.0 # find the network editor = hou.ui.paneTabOfType(hou.paneTabType.NetworkEditor) # collect the images stored in it backgroundImagesDic = editor.backgroundImages() # traverse all images, find the one we have actioned and set the brightness i = 0 for item in backgroundImagesDic: if hou.expandString(item.path()) == hou.expandString(image): backgroundImagesDic[i].setBrightness(brightness) break i = i + 1 # update the visibility values editor.setBackgroundImages(backgroundImagesDic) utils.saveBackgroundImages(editor.pwd(), backgroundImagesDic) # -------------------------------------------------------------------------------------------- # MAIN # -------------------------------------------------------------------------------------------- # generate unique(ish) path for screenshot timestamp = strftime('%Y%m%d_%H%M%S', gmtime()) hipname = str(hou.getenv('HIPNAME')) hippath = str(hou.getenv('HIP')) + '/screenshots' screenshotName = hipname + '.' + timestamp + '.png' systempath = hippath + '/' + screenshotName houdinipath = '$HIP/screenshots/' + screenshotName # take screenshot with capture region createScreenshotFolder(hippath) takeScreenShot(systempath) # set up background image plane editor = hou.ui.paneTabOfType(hou.paneTabType.NetworkEditor) image = hou.NetworkImage() image.setPath(houdinipath) sel = hou.selectedNodes() nullNode = '' if sel: lastSel = sel[-1] nullNode = lastSel.parent().createNode('null','screenshot') nullNode.setInput(0,lastSel) #if lastSel.outputConnections(): # nullNode.setInput(0,lastSel) else: nullNode = editor.pwd().createNode('null','screenshot') nullNode.moveToGoodPosition() lastSel = nullNode # configure image plane placement nullNode.setUserData('nodeshape','task') nullNode.setPosition(lastSel.position()) nullNode.setColor(hou.Color(.3,.3,.3)) nullNode.move([lastSel.size()[0]*2,-lastSel.size()[1]*2]) rez = hou.imageResolution(systempath) ratio = 1.0*rez[1]/rez[0] rect = hou.BoundingRect(0,-lastSel.size()[1]*1.1,widthRatio,-widthRatio*ratio-lastSel.size()[1]*1.1) image.setRelativeToPath(nullNode.path()) image.setRect(rect) # following is adding a spare parm with image path to be able to know which node corresponds to which background image # could have used a user attribute or relativeToPath() and smarter logic but it works and it helps visualize filepath hou_parm_template_group = hou.ParmTemplateGroup() hou_parm_template = hou.LabelParmTemplate("houdinipath", "Label", column_labels=([houdinipath])) hou_parm_template.hideLabel(True) hou_parm_template_group.append(hou_parm_template) nullNode.setParmTemplateGroup(hou_parm_template_group) # attach a function that deletes the background image plane if the corresponding node is deleted (faster than doing it by hand) nullNode.addEventCallback((hou.nodeEventType.BeingDeleted,), removeBackgroundImage) # attach a function to change visibility or opacity if corresponding node flags are changed nullNode.addEventCallback((hou.nodeEventType.FlagChanged,), changeBackgroundImageBrightness) # add image to network background backgroundImagesDic = editor.backgroundImages() backgroundImagesDic = backgroundImagesDic + (image,) editor.setBackgroundImages(backgroundImagesDic) utils.saveBackgroundImages(editor.pwd(), backgroundImagesDic)
  12. 1 point
    For anyone who googles out there I made a tool that I think matches what Julien wanted to do: https://berniebernie.fr/wiki/Houdini_Python#screenshot_to_background_image Code as of 22/07/2019 if my website goes down: import hou import os import subprocess import nodegraphutils as utils from time import gmtime, strftime widthRatio = 4 # change to make screenshot bigger or smaller, this is ~x4 node width def takeScreenShot(savePath): '''change to your preferred capture app /!\ no error checking for now ''' subprocess.check_call([r"C:\Users\me\MiniCap.exe","-captureregselect","-save",savePath,"-exit"]) def removeBackgroundImage(**kwargs): ''' erases bg image from tuples of backgroundImages() if it can find it, updates bg ''' deletingNode = [x[1] for x in kwargs.items()][0] image = deletingNode.parm('houdinipath').eval() editor = hou.ui.paneTabOfType(hou.paneTabType.NetworkEditor) backgroundImagesDic = editor.backgroundImages() backgroundImagesDic = tuple(x for x in backgroundImagesDic if x.path() != image) editor.setBackgroundImages(backgroundImagesDic) utils.saveBackgroundImages(editor.pwd(), backgroundImagesDic) def changeBackgroundImageBrightness(event_type,**kwargs): ''' changes brightness/visibility if template or bypass flags are checked -- its poorly written/thought but i was tired''' nullNode = [x[1] for x in kwargs.items()][0] image = nullNode.parm('houdinipath').eval() brightness = 1.0 if nullNode.isBypassed(): brightness = 0.0 elif nullNode.isTemplateFlagSet(): brightness = 0.5 editor = hou.ui.paneTabOfType(hou.paneTabType.NetworkEditor) backgroundImagesDic = editor.backgroundImages() i = 0 for item in backgroundImagesDic: if item.path() == image: backgroundImagesDic[i].setBrightness(brightness) break i = i + 1 editor.setBackgroundImages(backgroundImagesDic) utils.saveBackgroundImages(editor.pwd(), backgroundImagesDic) #generate unique(ish) path for screenshot timestamp = strftime('%Y%m%d_%H%M%S', gmtime()) hipname = str(hou.getenv('HIPNAME')) hippath = str(hou.getenv('HIP')) + '/screenshots' screenshotName = hipname + '.' + timestamp + '.png' systempath = hippath + '\\' + screenshotName houdinipath = '$HIP/screenshots/'+screenshotName #take screenshot with capture region takeScreenShot(systempath) #set up background image plane editor = hou.ui.paneTabOfType(hou.paneTabType.NetworkEditor) image = hou.NetworkImage() image.setPath(houdinipath) sel = hou.selectedNodes() nullNode = '' if sel: lastSel = sel[-1] nullNode = lastSel.parent().createNode('null','screenshot') if lastSel.outputConnections(): nullNode.setInput(0,lastSel) else: nullNode = editor.pwd().createNode('null','screenshot') nullNode.moveToGoodPosition() lastSel = nullNode #configure image plane placement nullNode.setUserData('nodeshape','task') nullNode.setPosition(lastSel.position()) nullNode.setColor(hou.Color(.3,.3,.3)) nullNode.move([lastSel.size()[0]*2,-lastSel.size()[1]*2]) rez = hou.imageResolution(systempath) ratio = 1.0*rez[1]/rez[0] rect = hou.BoundingRect(0,-lastSel.size()[1]*1.1,widthRatio,-widthRatio*ratio-lastSel.size()[1]*1.1) image.setRelativeToPath(nullNode.path()) image.setRect(rect) #following is adding a spare parm with image path to be able to know which node corresponds to which background image #could have used a user attribute or relativeToPath() and smarter logic but it works and it helps me visualize filepath hou_parm_template_group = hou.ParmTemplateGroup() hou_parm_template = hou.LabelParmTemplate("houdinipath", "Label", column_labels=(['\\'+houdinipath])) hou_parm_template.hideLabel(True) hou_parm_template_group.append(hou_parm_template) nullNode.setParmTemplateGroup(hou_parm_template_group) #attach a function that deletes the background image plane if the corresponding node is deleted (faster than doing it by hand) nullNode.addEventCallback((hou.nodeEventType.BeingDeleted,), removeBackgroundImage) #attach a function to change visibility or opacity if corresponding node flags are changed nullNode.addEventCallback((hou.nodeEventType.FlagChanged,), changeBackgroundImageBrightness) #add image to network background backgroundImagesDic = editor.backgroundImages() backgroundImagesDic = backgroundImagesDic + (image,) editor.setBackgroundImages(backgroundImagesDic) utils.saveBackgroundImages(editor.pwd(), backgroundImagesDic)
  13. 1 point
    Thats great! Going to use that, thanks for sharing your findings The techie tool is not my creation though, just really like it. Forgot to upload the little asset I created. attached it here. avg_color.hiplc
  14. 1 point
    Hi, Don't know of a way to do it with the color picker but you could always just do it in sops, I did a quick setup not very efficient. This is a great color sampler. https://techie.se/?p=gallery&type=houdini_assets&item_nr=6
  15. 1 point
    - gpu rendering for mantra and bake texture rop - split mantra render mode to render integrators like prman or render kernel like in octane - build a mantra PBR integrator that can only run precompile shaders for faster rendering - add a mantra post process node for custom LUT / Bloom / camera fx like in octane / maxwell - ability to output uv snapshot with the bake texture rop directly - new UI / interaction paradigm for manual task like modeling / uvlayout / sculpting / paint weight / blendshape / grooming / deformer - nodal / inline code GLSL shader tool to control the shaders and lights in the openGL viewport - openGL viewport LUT to match Unreal / Unity display - controlable GLSL viewport postprocess grain / vignette / bloom / LUT - perfect matching beetween mantra render and openGL preview, translation of VEX noise to their GLSL counterpart - display shader preview from external render engine in the shader palette - cops on steroid
  16. 1 point
    Someone answer me on the Redshift forum. There is a "redshift_instancefileSOP1" that do exactly that: enable to view the proxy in the viewport. I was not aware of that node.
  17. 1 point
    Alright so I just finished to study python (solo learn app ftw) to figure out how the python code works. For those interested: node = hou.pwd() geo = node.geometry() #these came by default with Python SOP, don't change it. nodeTrans = node.node("/obj/geo1/subnet1/objnet1/OUT") #nodeTrans receives the points and its data resulted of the objnet/extractgeo SOP mat = nodeTrans.worldTransform() #mat receives a matrix with the transform data of the points in the world, translate and rotate information matAttrib = geo.findGlobalAttrib("mat") #matAttrib receives the 'detail attribute' data from mat. In the first time in the loop it has zero data, so \/ if not matAttrib: matAttrib = geo.addAttrib(hou.attribType.Global, "mat", mat.asTuple()) #Turns the matrix data of mat in 'detail attribute' as Tuple else: geo.setGlobalAttribValue(matAttrib, mat.asTuple()) #if matAttrib already has something in it, put these values into 'detail attribute'
  18. 1 point
    i don´t know this tool but from watching the video i guess that it uses a non-rigid icp algorithm to match one geometry to another. there is no "out of the box solution" you can use in houdini but it isn´t too hard to wire together something that works in a similar way. please take a look at the attached file. it uses some pre-definded points on both geometries to guide the general alignment and deformation. if you want this to work without any user input it might become more tricky but should also be doable ... hth. petz non_rigid_icp.hipnc
  19. 1 point
    I'm creating a short design/vfx film about the birth of Venus. The film will be divided into three acts. Act 1, the discarded part of Uranus cast into the ocean. Act 2, Venus forms from sea foam. Act 3, rising from the water. It will be a highly stylized and a creative interpretation of the story. Almost all of the film will be done in Houdini, mostly by myself. Character animation will be done in Maya, but rendered in Houdini, as well. As I'm nearing completion on Act 1, I'm going to start posting WIP shots here and little R&D tests. So, to start, here are the first two shots. 100% Houdini, except for the background sky plate. Composited in Nuke.
×