Home Coding, Scripting, Shaders
The BRAWL² Tournament Challenge has been announced!

It starts May 12, and ends Oct 17. Let's see what you got!

https://polycount.com/discussion/237047/the-brawl²-tournament

Tech Artist - What are you working on: FOREVER Edition!

Replies

  • poopipe
    Offline / Send Message
    poopipe grand marshal polycounter
    image.png

    grabbing this now

  • onionhead_o
    Offline / Send Message
    onionhead_o polycounter lvl 17

    Very Impressive stuff ! pi3c3

    Heres a attempt at blenders vertex extrude inside maya


  • Klunk
    Offline / Send Message
    Klunk quad damage

    shape emitter modifier

    spline_emitter.gif


    with min spacing and texture map density (gradient ramp in this case)

  • Klunk
    Offline / Send Message
    Klunk quad damage

    a little arcane (and a right pain to workout/code) perhaps but I've managed to get my point emitter to be a "proper" max pipeline object like editable mesh, splines and poly. Doesn't sound much but it saves a lot of faff with each emitter having to handle everything individually can now be moved to a single mod that works on all emitters (as well as all deformer mods working too :D )


    pipeline2.gif


    a base emitter object with taper mod and a stretch mod added then collapsed back to base emitter object.

  • Klunk
    Offline / Send Message
    Klunk quad damage

    how it works for my tree creator


    taper.gif

    procedural sphere emitter with a taper mod

  • Klunk
    Offline / Send Message
    Klunk quad damage

    another demo of having emitters as a pipeline object

    conform.gif

    procedural spherical emitter with a conform to mesh modifier applied used to generate a mesh at each point (yet to code the mesh normal to emitter normal so the generate mesh can align to the surface)


    conform2.gif

    spline emitter above with conform to mesh mod

    conform3.gif

    with normals

    grass.gif

    an "ocean" of grass (rotating the terrain under the emitter which is conformed to the terrain and spawning the grass meshes)

  • Klunk
    Offline / Send Message
    Klunk quad damage

    Implemented the most simple of interfaces for SimpleObject2 class in max called IVariation. And all it does is invalidate the mesh forcing max to rebuild it. So now if you add any kind of random variation in your object creation this can be reflected in the creation process

    ivariation.gif

    as a test I randomized the height segment in a cylinder object being used my emitter cloner object

  • hannes d
    Offline / Send Message
    hannes d polycounter lvl 12

    made a free max plugin https://github.com/hannesdelbeke/dark-listener-max
    to get dark mode for the listener automatically on startup

    image.png
  • Klunk
    Offline / Send Message
    Klunk quad damage

    kind of hilites the harsh white window surround now :)

    so much wrong with that window! why is there a scroll bar ? is there invisible text going off the end of the page ? (I'm having a go @ Autodesk and their usual half arsed approach btw :) )

  • another caveman
  • Klunk
    Offline / Send Message
    Klunk quad damage

    kind of, different meshes, though still "static" as the "terrain" moves under them.

    considerably more geometry with the grass :)

    grass.jpg
  • Klunk
    Offline / Send Message
    Klunk quad damage

    first proper object that uses my variation interface, It basically a foliage fan, where you can vary the number of fans and their height, shear, shift, slide, normals, vertex color, atlas mapping, uflip etc

    ivar_demo1.gif

    the animation is showing a new instance of the original object at each point (the blue dots) which is then merged to a combined mesh.

    abit denser

    grass_ball.gif

    and a still

    gball.jpg klunk_grass.jpg
  • Klunk
    Offline / Send Message
    Klunk quad damage
    a bit of fluff ;) added the ability to draw an image in screen space of the max viewport with alpha

    so you could in theory have a custom hud :)


  • PolyHertz
    Offline / Send Message
    PolyHertz polycount lvl 666
    @Klunk is that being done via maxscript or the SDK? I tried doing something similar at one point with Maxscript gw drawing methods but viewport performance was terrible with it.
  • welbot
    Offline / Send Message
    welbot discord admin
    yes I'd be keen to know too! We tried this at a studio an age ago, but never had any luck!
  • Klunk
    Offline / Send Message
    Klunk quad damage
    SDK, using a call to the GraphicsWindow::triStrip function (though just a quad). Though it gets tricky in that if the viewport is in perspective you have to force the camera into orthographic projection or otherwise you get really noisy and strange behaviour at extreme zooms. The texture handling I use is much the same as used in the  maxsdk\howto\ViewportTexture sample, you create a Texture handle with GraphicsWindow::getTextureHandle then set this you then assign this to a Material (not to be confused with (Mtl)). Then you use GraphicsWindow::setMaterial before drawing the tristip.
  • Klunk
    Offline / Send Message
    Klunk quad damage
    slight deviation, a max script that adds helpers to a spline shape so it can be manipulated when at the bottom of a stack without needing to go to into the stack and to subobject editing


    it came about as a "reverse" of the points to spline thread, i'll post it up once most of the bugs and random crashes are ironed out :anguished:
  • slrove
    Offline / Send Message
    slrove polycounter lvl 6
    Working on lots of strap rigs, have to restrain a character in VR.  
  • malcolm
    Offline / Send Message
    malcolm polycount sponsor
  • Polynaught
    Offline / Send Message
    Polynaught polycounter lvl 12
    omg, wouldn't even know where to begin with that rig, nice one
  • Senorpablo
    Offline / Send Message
    Senorpablo polycounter lvl 12
    Klunk said:
    slight deviation, a max script that adds helpers to a spline shape so it can be manipulated when at the bottom of a stack without needing to go to into the stack and to subobject editing


    it came about as a "reverse" of the points to spline thread, i'll post it up once most of the bugs and random crashes are ironed out :anguished:
    That's really neat. Is that real-time triangulation, Delaunay or otherwise?
  • Klunk
    Offline / Send Message
    Klunk quad damage
    thanks, Constrained Delauney poly2tri  (though i've change some of the source code to work better with max) it's real touchy about duplicate points or points outside the constrained polyline (crashtastic :) ) otherwise it just a modifier that fills the spline with grid points and an optional border loop. I have another one in the same vane that uses a second curve to control the direction of the interior grid points.
    I use poly2tri quite a lot,  though you have to create the tris in 2d it works really well in conjunction with max's Mesh class, it's good for retriangulation and fills etc. Also you have to provide your own quadifying and quad edge alignment routines as it only produces tri and edge direction with the grid can be quite random.
    It does better (neater) job with triangulation when the either the length or the width of the polyline is biased to one or the other, if equal it does a pretty poor job.... it and easy work around as you are only really interested in the triangulation you can scale the points you pass to it in either x or y.

    quick demo with textures

    the modifier also defines its bounding edges as an Outline which can be used by a cutting modifier (also using poly2tri)



  • Klunk
    Offline / Send Message
    Klunk quad damage
    another diversion :)

    doing the above demo snippet,  I approximated the mapping of the two objects to similar scaling an position though the illusion is ruined the moment I rotate the entire object :anguished: So it got me thinking about linking the mapping gizmo of both objects to a helper..... seems it works :)


    the script sets a uvw mapping mod to each object (using the largest width and length for each) and linking the gizmo tm to the helper object via transform script.


  • Eric Chadwick
    Wow two Front Pages in a row. Killing it.
  • Klunk
    Offline / Send Message
    Klunk quad damage
    A modifier to turn any geometry into a cutter (Outline) than can be used in my cutting modifier, currently using open edges will be extended to any edge selection.


  • Klunk
    Offline / Send Message
    Klunk quad damage
    have to say I'm a little blown away with this one  B)  ;)

    a cylinder with a slice mod (gizmo tied to a helper similar to the mapping script) then an outliner mod. and used as a cutter.



  • Klunk
    Offline / Send Message
    Klunk quad damage
    nice as the ouliner mod is it threw up a few possible issues (revealed by extruded max text not capping correctly :angry: ). So I need to test some boolean operation on the outlines so added some shape booleans ops to max script to aid this....


    does union (show with resample mod applied), difference, intersection and xor (intersection and union)
    works with "holes" too


  • slrove
    Offline / Send Message
    slrove polycounter lvl 6
    Update/highlights on these restraint rigs, after animation, and brought into Unity. This is just a timeline preview for animation purposes. Normally I would integrate animations into character controllers for interactive experiences in VR, but I'm trying to focus on the tech art animation side and let developers make use of my clips. Ended up being a bit more complicated than estimated, knowing it was going to be a challenge to: restrain a character, buckle in the straps, and tighten it. Him fiddling with his mask ended up surprising me and became my favorite part.
    I've done enough work on this to make a talk out of it.... maybe I might. There are 7 different rigs working in tandem to make this happen. Post-mortem: try and fake it simpler next time  ;)
      

  • Klunk
    Offline / Send Message
    Klunk quad damage
    I've been implementing my own com server for max (going through mxs can be a bit of a faff :) ) to add addition dev tools  anyway it paid dividends straight away helping to get a better algorithm for find what in or not in a polygon not matter what the depth or heirarchy.



    now onto how to deal with intersections, my brain hurts!
  • malcolm
    Offline / Send Message
    malcolm polycount sponsor
    That is so neat.
  • slrove
    Offline / Send Message
    slrove polycounter lvl 6
    Wow, that is impressive Klunk.  B)
    When I first saw some of your posts about this, I was wishing I had an easy way to create something like this for a terrain shader I had developed. The shader mixed materials based on vertex color so certain terrain features would require specific vertex placement to retain material transitions. For example a dirt path would need the vertices along the edges to blend into the terrain nearby, and my only method at the time was painting in subdivisions essentially. When the terrain was a grid, it was too easy to spot the "resolution" even with height blending and soft vertex color changes. This would be awesome to have(if I were in max) becuase I can't trust maya's booleon operations, especially with history.
    Developing solutions that cause brain pain isn't all bad (in healthy doses). Its just a sign you are pushing your understanding of some very technical processes.
  • Klunk
    Offline / Send Message
    Klunk quad damage
    playing around with a different triangulation routine I stumbled upon.....
    top is the new one, middle is the sweepline (which is what I tend to use though it's not without it's issues) and max's good ol' ear clipping standard bottom. You can get a similar result for the sweepline for the circle if you scale it down in x or y just to resolve the topology but you would need to know this before hand.
    in conclusion, on what you would normally come across it does a pretty good job the x & c would be a pretty rare occurance in the "wild" that said it does a pretty good job on the c :astonished:

  • poopipe
    Offline / Send Message
    poopipe grand marshal polycounter
    ohhh, that's not bad at all 

    what's it called?  or did you invent it?

    ear clipping sucks - i've been getting good results using a version of the old triangle library I ported to python but I don't think it would work that well on the circle
  • Klunk
    Offline / Send Message
    Klunk quad damage
    Not I :) , found it in a book.... mathematics for 3d game programming and computer graphics Eric Lengyel page 270 (IIRC he did a method for generating tangent space vectors)
  • Klunk
    Offline / Send Message
    Klunk quad damage
    had a bit of a doh! moment and a humble brag ;) I wrote a documentation generator a while back to handle my MXS extension function libraries (i tried DOxygen but never really liked it's output). It basicaly works by using embedded xml snippets describing functions and it arguments but also as documentation within the code too, it the converts the snippets in html. Its then called post build and pipped to HCC compiler. Anyway I recently needed to update it for documentation of the max com server I was working on which is a cpp interface. Anyway to cut a long story short I discovered the wonders of style sheets :anguished: and the em tag. Everything is just so easy now :) what the fuck was I thinking !!! It's about 3 times faster a gizillion times less complicated and files are now miniscule! I've included a sample file (though note the colors and fonts are just messing around and one of the font may not display as intended)
  • Klunk
    Offline / Send Message
    Klunk quad damage
    down the rabbit hole today :)

    working on how my tree generator operates as a point emitter -- how fronds and or leaves are distributed, well partularly how the normal directions are aligned (the position bit is a piece of piss)

    had the idea of a wheel like control with regions that turn on and off when on the normals can go in that direction and off they can't.

    then it hit me, thats a gradient ramp of sorts with a radial output and actually a gradient could be useful.

    cool I've got one of those but it takes up a lot of bloody room and not very intuitive with a radial output :/

    what about an actual radial gradient control much like the gradient ramp, bit more compact....

    so off we go, and now I'm working how render "3d" marker stops that work correctly in any direction :anguished: 



    least it will look "pretty" :)
    how it might look in a max rollout

    perhaps a little busy :anguished: , might be best in it's own dialog :/

  • poopipe
    Offline / Send Message
    poopipe grand marshal polycounter
    wait up... explain that again

    I dont care about the UI - what's the logic as you run up the tree?
  • Klunk
    Offline / Send Message
    Klunk quad damage
    in the above example the emitter normals would be most likely point  in the direction where the gradient is whitest when looking end on to a branch (radial angle), the longitudinal angle is pretty simple. 
    the most obvious example would be to make something like....

    using something like....

    or something like....

    with...

    have also been considering a "3d ball with cones (think spotligh cones hotspot & fall off)" gizmo one for the start and one for the end think that may get busy too.
    I do have a working solution already...

    just needs tweaking for more specialist cases so to speak.

  • poopipe
    Offline / Send Message
    poopipe grand marshal polycounter
    ah - now it makes sense. 

    this is coming on rather well.  
    death to speedtree!!

  • Klunk
    Offline / Send Message
    Klunk quad damage
    I doubt it :) they have some good tech but i never liked it (too many "duff" trees and too many sliders)
  • Klunk
    Offline / Send Message
    Klunk quad damage
    it works after a fashion....


    still trying to find ways of improving the middle of the gradient :/
  • ZacD
    Online / Send Message
    ZacD quad damage
    Could go the lazy route a put a dot in the middle :)
  • Klunk
    Offline / Send Message
    Klunk quad damage
    I'm thinking big hole ! ;) I could stick something in there or have opacity stops running on the inside

  • hanabirano
    Offline / Send Message
    hanabirano polycounter lvl 6
    Klunk said:
    playing around with a different triangulation routine I stumbled upon.....
    top is the new one, middle is the sweepline (which is what I tend to use though it's not without it's issues) and max's good ol' ear clipping standard bottom. You can get a similar result for the sweepline for the circle if you scale it down in x or y just to resolve the topology but you would need to know this before hand.
    in conclusion, on what you would normally come across it does a pretty good job the x & c would be a pretty rare occurance in the "wild" that said it does a pretty good job on the c :astonished:

    This is rly cool! Is it possible to have the top one has a modifier and with the option of only doing quadringulation?
  • Klunk
    Offline / Send Message
    Klunk quad damage
    thanks, quadifying meshes is proper "down the rabbits hole" stuff :) 

    on a side note this was a fun bit of coding.... radial checker (to show transparency)
     
  • Klunk
    Offline / Send Message
    Klunk quad damage
    add new method for my spline emitter for the distribution to avoid clumping on inside corners and sparsity on outside corners

    a few issues on closed spline with max sdk returning some funky tangent values on corner knots  :/

  • SimonT
    Offline / Send Message
    SimonT interpolator
    I'm working on a little game and made a breakdown post on artstation: https://www.artstation.com/artwork/OG6A5e
    (sorry, the forum seems very broken and neither my preview image as link nor upload shows up....)


  • ZacD
    Online / Send Message
    ZacD quad damage
    I hope this is tech arty enough, but a simple procedural powerline setup in UE.

    https://www.youtube.com/watch?v=uM5UJWxy6TM
  • Klunk
    Offline / Send Message
    Klunk quad damage
    been playing around with adding perlin noise to my gradient controls.....

  • poopipe
    Offline / Send Message
    poopipe grand marshal polycounter
    is that a custom curve for interpolation at the bottom? 
Sign In or Register to comment.