Jump to content

Juraj

Members
  • Content count

    354
  • Joined

  • Last visited

  • Days Won

    15

Everything posted by Juraj

  1. Hello, in Houdini 15 I was using hou.ui.selectFile() dialog to get user's input and I would process it further in python. I used the same function to let user select files or folders, based on the needs of a tool. Now I updated to 16 and the function does not seem to enable user to select a folder, it works only with selecting a file. Does anybody know if there is a way to select a folder in 16? I want to batch process files in a directory and I would like to use file browser dialog to let user set it. In worst case I could use hou.ui.readInput(), and to ask user to enter a path there, but this is super user-unfriendly Thanks, Juraj
  2. Pulse of Life

    Hello, now when it is finally published I would like to share you something I was working on during my first semester at the university. It is an university project done at Filmakademie Baden-Wuerttemberg and my role was Technical Director. Enjoy watching with loud sound and in HD Big thanks goes to our cool team, who did their best to finish this piece: Concept/Design: Alex Berweck Technical Directing: Juraj Tomori Film Music: Alexander Wolf David Sounddesign: Robin Harff Animation-­/ VFX-Producing: Vincent Waltan, Tina Vest Modeling: Mitja Öhm Director and Layout: Caroline Kießling FX & Simulation: Aleksej Skrypnik, Justin Braun Production Company: Filmakademie Baden-Württemberg GmbH Pipeline was centered around Houdini and Mantra and we really enjoyed the production of it. I did short breakdowns of a tools and workflows I developed for this project, you can check it here: https://vimeo.com/album/4471569 We used a lot of assets and relied heavily on instancing and I really liked how well Houdini suited into our pipeline, from fast viewport preview of packed disk primitives, to lightweight IFDs being constantly sent to renderfarm Also using digital assets enabled us to efficiently collaborate and transfer setups to the shots. Also big thanks to awesome people here at odforce, it was really great learning/help resource for our project. If you have any questions feel free to ask Juraj
  3. Hi, I tried to update to latest build 16.0.736 (linux), but it isn't working. I can simply select files, but when I select folder and click accept, nothing happens, selection is accepted only if I select a file. In 16.0.557 it works normally, but not in 16.0.600, 16.0.633, 16.0.736
  4. Juraj's playground

    Hello community, I am creating this thread where I will be posting links to my tests, experiments, RnD's and other uncategorizable stuff. Also often I will include scene files so feel free to explore them and to learn how not to do things ...hope it will help somebody, somehow. Juraj
  5. Selectively load volume from VDB file

    So, I just found out, that OpenVDB's Houdini implementation has a node for exactly this purpose From node's docs:
  6. Hello, now when I am loading VDB volumes with File SOP it sometime takes some time, especially with big volumes stored on network. I was wondering whether it is possible to load only specified volumes from a VDB file, for example to load only heat, to keep loading times slower. This would save a lot of time in situations where I am blasting all other volumes which I do not need directly after File node. I quickly checked docs and found that it is possible to firstly read the header to find out information about stored VDBs and then to load needed volume (in Reading and modifying a grid section). Any ideas if it is supported right now in Houdini implementation / or if there are any plans to add this? Juraj
  7. Pulse of Life

    Thanks, we also appreciate your feedback and help during the production
  8. simple vector problem

    Hi, you can compare angle between two vectors with dot product: the normal vector (v@N) and vector pointing from second point to the first one (v@difference = pt2 - pt1 , (pt1 and pt2 are positions of first and second point) ) and if angle is positive, then the second one is in front of, if negative, the second one is behind the first one. Pseudo code could look like it if (dot(v@N, v@difference) > 0) //second point is first else //first point is first
  9. Juraj's playground

    Hi, unfortunately I cannot share the whole setup. I shared as much as I am allowed in the blog post explaining the process of implementing this technique. Hopefully later I will be able to put it here, but not now.
  10. Hello, does anybody know how to render flat shaded scene from OpenGL ROP? I need to do some viewport renders and I would like to have the exact look as in the viewport when set to flat shading. OpenGL ROP renders out stuff in smooth shading, even if it is set to flat. Is it a bug, or I am doing something wrong. Thanks, Juraj
  11. OpenGL ROP and flat shading issue

    My bad, now I see, that I actually want to disable lighting component (specular) in the OpenGL ROP in the same way as I would do in the viewport when right clicking on lighting in display options toolbar. Edit I figured it out, after assigning a constant shader, then speculars go away, this viewport if too fancy for my needs
  12. Juraj's playground

    car_paint_shader.zip
  13. GLSL shader questions

    Hello, I would like to experiment with GLSL shaders in Houdini viewport a bit, but I had very little success yet As a simple thing I would like to create a "matcap" shader, I have this shader in mantra and it works well, but it is quite simple logic in it and I would like to try it out in GLSL as well. I tried two approaches for creating glsl shaders: New Operator Type - SHOP Type - GLSL Shader This approach does not give me any results, the default shader has quite complex code and in the viewport I can see only white color. I tried to modify couple of variables in the code to at least change color from white to red, but unsuccessfully Reference ogl_glsl_shader parameter on a shader pointing to shader.prog file which references to shader.frag and shader.vert This gives me results in the viewport and works quite well, however I do not know how to reference node's parameter value to the GLSL variables. I created those files based on examples in $HFS/houdini/glsl //fragment shader in vec2 matUv; out vec4 color; uniform sampler2D tex; void main() { vec3 base = texture2D( tex, matUv ).rgb; color = vec4( base, 1. ); } First question: how can I reference parameter on the node to the tex variable in opengl? When googling I found some examples which implied that only creating string parameter tex should work, but when running their example files I never got any result in the viewport. Second question: is this the correct workflow? How could I achieve the same thing with New Operator Type workflow? Do you have some simple examples of those nodes with basic shading? E.g. sampling a texture, using constant color... Thanks for any clarification, Juraj
  14. RGB to Kelvin

    Just thinking out loud - color of blackbody radiation can be represented by temperature in Kelvins, or RGB color it emits. So Kelvins to RGB mapping should be straight forward, but backwards it might be tricky, as a RGB value may not be present in blackbody radiation spectrum. If I understand it right, then this plot is showing Kelvin temperatures mapped to RGB colors. So solution that comes to my mind is to find a Kelvin value, which is closest to the given RGB value. One way would be to take an array of Kelvin values converted to RGB values and to find the closest match (based on euclidean distance). Or if array of Kelvin values is not dense enough, you can linearly interpolate between two closest points found. It is not very precise, but should be good enough for some cases. Also, one more fancy thing would be to compute the distance of given RGB value and Kelvin sample in Lab color space, because if I remember correctly, then distances in Lab color space match the best to the perceived difference in colors (Maybe it is some other space, you can look it up)
  15. Juraj's playground

    I also wrote a blog post describing my approach, feel free to check it here.
  16. Juraj's playground

  17. Juraj's playground

  18. Juraj's playground

    Hello, thanks! Glad you like it Unfortunately I cannot share scripts because of the university policy, but will try to write a new one save incremental function # splits versioning string into letter and number, e.g. v025 -> ['v','025'] def verSplit(ver): head = ver.rstrip('0123456789') tail = ver[len(head):] return head, tail # save incremental, tries to preserve version formatting def saveInc(): hipname = hou.getenv('HIPNAME') if hipname != 'untitled': v, num = verSplit( hipname.split("_")[-1] ) num = str( int(num) + 1 ).zfill( len(num) ) newName = hipname.split("_") newName[-1] = v + num newNameStr = hou.getenv('HIP') + "/" + "_".join(newName) + "." + hou.getenv('HIPFILE').split(".")[-1] hou.hipFile.save(newNameStr) else: print "cannot increment version name in untitled.hip" Hi, thanks Maybe, but this setup is not very portable and was made for our pipeline. It would require a bit of work to prepare for release and to make it work in most of the environments. LOD switching would not require much of work in this setup. Just computing distance to render camera and then thresholding it into an LOD attribute. But in our case manual decisions proved to be most suitable.
  19. Hi, probably building simple solver could help you. Check out those tutorials, they explain how to build simple and fast fluid solver. If I understood correctly, you need to initialize velocity volume (sampled on faces), then for each simulation step: inject into it velocities from animated geometry, do divergence-free projection, advect velocity by itself and repeat... Probably you might need to enforce boundaries to zero out velocity within geometry.
  20. Juraj's playground

    Here is collection of breakdowns for a project I was working on during last half of a year Vimeo album: https://vimeo.com/album/4471569 Or individual videos:
  21. Juraj's playground

  22. Hello, I am trying to remove overlapping polygons - I want to do so by computing distance to other polygons using xyzdist(). So I want to specify primgroup which will contain all, but current primitive, so that It is not returning distance to itself. According to documentation, I should pass group string which matches general SOP syntax. So for polygon number 240, primgroup parameter should be "* ^240". When I pass this parameter to the function, it returns -1 in found primitive - no primitive found. I think that the error is causing by this primgroup parameter. If I pass for example "*", then there is also no primitive found. How can I use patterns to define group inside this function? Like 0-50, *, ... This is from the docs: The name of a primitive group or a pattern to generate a primitive group. Uses the same semantics as a SOP group, so empty strings will match all primitives. Any ideas how to make this pattern working? Juraj
  23. Hello, I am struggling with adding all deep render properties inside a mantra node with python. To do so manually via interface is quite simple, I go to node - edit render properties - filter *deep* - add them all. However I am modifying mantra nodes with python and it would be great if I could do the same thing automatically. So far it seems rather tedious - I need to create all ParmTemplates, match their signatures and append to a FolderParmTemplate and set this to the node. Another thing worrying me is menu parameters - I do not need to create interface with menus, can I only set the desired value? Is it equivalent to creating a string parameter and setting it's value to menu item's name (not label)? Thanks, Juraj
  24. python add all deep render properties

    So I realized, that it is not possible to set rendering properties as mantra command line arguments. But I found cool solution for my problem, it can be done easily with hscript. opproperty -f /out/mantra1 mantra* *dcm* This did the trick, I am calling it with hou.hscript() in Python.
×