Igor Posted November 10, 2016 Author Share Posted November 10, 2016 (edited) Thank you very much Petz! File is very good to help me understand Gradient better. Edited November 10, 2016 by Igor Quote Link to comment Share on other sites More sharing options...
Igor Posted November 15, 2016 Author Share Posted November 15, 2016 @petz In your File you orient uv.y to direction of Gradient for visualisation. Can we orient uv and texture to Vectorfield? Thanks! Quote Link to comment Share on other sites More sharing options...
petz Posted November 19, 2016 Share Posted November 19, 2016 On 15.11.2016 at 4:43 PM, Igor said: @petz In your File you orient uv.y to direction of Gradient for visualisation. Can we orient uv and texture to Vectorfield? Thanks! well, aligning texture coordinates to a vectorfield is not trivial if this is what you want. generally you could use a small texture patch and distribute it over the surface by aligning it to the vector or you could generate the uv´s based on the vectorfield. the first one is fairly simple to implement in the shader but might result in visible texture boundaries if they are not blended together accordingly. the second one would be better but harder to implement and depending on the vectorfield not always possible. for the vector field in the file above for example, it is fairly easy to aligning u OR v (actually this is already done in the file for visualizing the contour lines) but aligning u AND v wouldn´t be possible without partitioning the mesh. is this what you meant or did i misunderstand the question? Quote Link to comment Share on other sites More sharing options...
Igor Posted November 20, 2016 Author Share Posted November 20, 2016 Thank you for answer! What I want to ask is method to match direction of texture uv to direction of random vector field. Can we not deform surface with same method as contour line visualisation to set uv to follow vector? Quote Link to comment Share on other sites More sharing options...
petz Posted November 21, 2016 Share Posted November 21, 2016 (edited) On 20.11.2016 at 2:55 AM, Igor said: Thank you for answer! What I want to ask is method to match direction of texture uv to direction of random vector field. Can we not deform surface with same method as contour line visualisation to set uv to follow vector? if i understand you correctly than you would like to have texture coordinates following an arbitrary vectorfield, right? if so, then this is not going to be easy. the problem is this: depending on the vectorfield you might be able to calculate for example uv.x by basically solving the poisson equation but this means that it has to be a gradient field. however, for an arbitrary vectorfield that´s most likely not the case and even if it is, you´ll probably get into troubles with the other direction. to calculate uv.y you have to compute the orthogonal vectorfield to the original one and once again you´ll have to set up a linear system based on the fact that the laplacian is the divergence of the gradient. and here is the problem. if the original vectorfield is curl-free, the orthogonal one is most probably not or vice versa. so you´ll have to set up a pretty complicate non-linear system and even then it might not be possible to align the uv´s exactly along the vectorfield without partitioning the mesh. practically speaking, the easiest way would be to just paint the uvs or try to do it in the shader by blending together aligned texture patches. both should work fine. if this is not practice-related but learning-related, well, get your hands dirty! hth. petz Edited November 21, 2016 by petz 1 Quote Link to comment Share on other sites More sharing options...
Igor Posted November 22, 2016 Author Share Posted November 22, 2016 Thank you! I do not understand method but it does sound very complex I try to understand after more reading in math book Quote Link to comment Share on other sites More sharing options...
eetu Posted November 23, 2016 Share Posted November 23, 2016 On 11/22/2016 at 1:21 AM, petz said: if i understand you correctly than you would like to have texture coordinates following an arbitrary vectorfield, right? if so, then this is not going to be easy. Just think out loud here, this might be interesting to hook together with a texture synthesis algorithm, then the divergence would not be a problem.. maybe Quote Link to comment Share on other sites More sharing options...
petz Posted November 25, 2016 Share Posted November 25, 2016 On 23.11.2016 at 0:30 PM, eetu said: Just think out loud here, this might be interesting to hook together with a texture synthesis algorithm, then the divergence would not be a problem.. maybe wouldn´t this be quite the opposite of what igor wants? i mean, by pasting and blending texture patches together in the shader you are basically already using a texture synthesis algorithm. the drawback is that you´ll end up with either a large baked out texture or you are tied to the software you have written the shader in. i think what igor meant was to assign the uvs of the mesh in such a way that they are aligned along the vectorfield. divergence isn´t the problem here, curl it is, but with orthogonal vectorfields it´s hard to get rid of one without getting into troubel with the other ... anyway, i fully agree that in practice it makes much more sense to use some texture synthesis approach instead of the other one. for "pure learning purposes" it might be the opposite ... Quote Link to comment Share on other sites More sharing options...
Igor Posted November 30, 2016 Author Share Posted November 30, 2016 Thank you eetu and petz! @eetu I did search for Texture Synthesis and found it very informative but i do not know how to translate it to Houdini . Do you have good link or advice where to start? @petz I did first think it is possible to deform mesh as you did in example to get texture follow Vector field. I did not know how complex it is. To much Divergence, Curl, Poisson I do not understand. Thanks again! Quote Link to comment Share on other sites More sharing options...
Librarian Posted September 1, 2020 Share Posted September 1, 2020 Here its some Links For Math! Some req -Scipy python . http://page.math.tu-berlin.de/~chern/projects/Clebsch/ http://www.multires.caltech.edu/pubs/pubs.htm http://wordpress.discretization.de/houdini/ http://dgd.service.tu-berlin.de/wordpress/geometryprocessingandapplicationsws19/ http://wordpress.discretization.de/ddg2019/ Have Fun....80 % files incl..and vex just do some searching... 2019-2016 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.