Jump to content


Regular Member
  • Content Count

  • Joined

  • Last visited

Community Reputation

1 Poor

Profile Information

  • First Name
  • Last Name
  • C4D Ver
    19.053 Studio

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hi João, hope you are well :) Um, thats not quite what I need (apologies, I may have confused things by mentioning the fresnel). What I need is this:
  2. Howdy all, I've decided (after enough head-smashing-against-the-desk) that I need some help. I need a selection / vertex map that returns 1 if facing camera and 0 if facing away. Effectively recreating the results of the Normal Direction shader. I got kind of close using the Shader Field… which seems to work when driven by fresnel… but won't play nice with the Normal Direction shader (see below screenshots and attached project file). Any help would be much much much appreciated :) Here is the Normal Direction shader applied to a tube. backfiring polygons are black: This has been fed into a Shader Field driving a vertex map, but it isn't affecting the vertex map whatsoever: Here is the same setup, using Fresnel instead, which is working: Im hoping Ive missed something dumb (maybe to do with projection?), because the above solution seems like it just should work. But hey, perhaps there's an even simpler way- if you know what's going on, please lend a hand :) ShaderField.c4d
  3. Ohhhhkay... I think this makes sense to me. My brain is still a little exploded about it, and I'll have to try and break things down a bit more- before I'm certain I know what's going on here. Thank you very much for taking the time to explain things so clearly. I'm very new to scripting stuff so appreciate the hand holding :)
  4. Ah man, I still can't seem to work this out, any help would be appreciated. I simplified the project file a bit (attached) Spline Rig 02c.c4d
  5. Hey there. I've run into some trouble with a little script I'm hacking together, hoping someone could spare a moment to take a look? I'm just trying to connect the components of a spline to some arbitrary nulls within my document. So far everything seems to be working, except the tangents- which are not positioned where their corresponding nulls are. Document attached and code below. import c4d #Welcome to the world of Python def main(): MySpline = op.GetObject() #This is the spline. P1 = op[c4d.ID_USERDATA,1] #First point T1L = op[c4d.ID_USERDATA,3] #First point's left tangent T1R = op[c4d.ID_USERDATA,4] #First point's right tangent P2 = op[c4d.ID_USERDATA,6] #Second point T2L = op[c4d.ID_USERDATA,7] #Second point's left tangent T2R = op[c4d.ID_USERDATA,8] #Second point's right tangent MySpline.SetPoint(0, P1.GetMg().off) #Set position of first spline point MySpline.SetPoint(1, P2.GetMg().off) #Set position of second spline point MySpline.SetTangent(0, T1L.GetMg().off, T1R.GetMg().off) #Adjust tangents for point 1 - Not Working! MySpline.SetTangent(1, T2L.GetMg().off, T2R.GetMg().off) #Adjust tangents for point 2 - Not Working! MySpline.Message(c4d.MSG_UPDATE) Spline Rig 02b.c4d
  6. Wow, thanks for all this dude! I can't give it a go until I have access to cinema again tomorrow, but really looking forward to geeking out with this stuff :) Also thanks for taking the time to explain what I had wrong in my hacked together script, will be helpful in the future as I get my head around all this stuff
  7. Thanks Kalugin, I really appreciate your time working on this. I've tested the script and it works pretty nicely. I do have an issue and a question. Issue: When inserting a Generator (as parent of an object) it should be placed in the same global position and rotation as its child. Is this possible to implement? Question: I'll be making a bunch of these scripts, one for every Deformer and one for every Generator. Would it be better to split out the Generator code and Deformer code, so Generator scripts don't care about Deformers and vice versa? I've attempted to do so here (creating a Generator only script, but sadly this doesn't run– because I just don't know things. import c4d clonerObject = c4d.BaseObject(1018544) def addGenerator(generator, objs): selectedObjects = doc.GetActiveObjects(0) if len(selectedObjects) == 0: doc.InsertObject(generator) doc.AddUndo(c4d.UNDOTYPE_NEW, generator) else: for obj in selectedObjects: new_generator = generator.GetClone() new_generator.InsertBefore(obj) doc.AddUndo(c4d.UNDOTYPE_NEW, new_generator) doc.AddUndo(c4d.UNDOTYPE_CHANGE, obj) obj.InsertUnder(new_generator) def main(): addGenerator(clonerObject, selectedObjects) if __name__=='__main__': main()
  8. Well damn, hit a frustrating roadblock. Trying to make shortcut keys for Generators and Deformers, but annoyingly these shortcuts don't play nice with modifiers (So can't insert as parent/child via option/shift modifiers). Going to need to use scripts here too (unless theres a trick Ive missed?). Can anyone help scripting out something like this: "If an object/s are selected, create Deformer/s as child of object/s, otherwise just create Deformer" and one for Generators that goes "If object/s are selected create Generator/s as parent of object/s, otherwise just create Generator"
  9. This little guy is also interesting https://www.elgato.com/en/gaming/stream-deck
  10. http://www.tipro.net/ecatalogue/128-programmable-keys/
  11. “Point of Sales” keyboard. It’s a checkout keyboard designed for shops. Fully customiseable with onboard memory. Pretty cool really :)
  12. Awesome thanks so much, that’s going to get thing rolling! I’m terms of control surface, yeah I have these 2 programmable POS keyboards, each with 128 keys with relegendable key caps. Have had them for years and just now thinking of ways I can use them :) The more I think about this, the more exciting it becomes! Thanks for your help!
  13. Wondering if anyone (who's a little more expresso/script savvy than I) could weigh in on the possibility of getting something like this set up… I'd like to control specific attributes with keyboard shortcuts. For example hitting Shift+1~1 would increase a specific user data slider by 10 units. If I could get this set up, I could create a kind of simple hardware control surface for animation. No idea if I'm "pie in the sky" thinking on this one?
  14. hmm okay that makes sense and thank you for taking the time to explain things so succinctly. I've worked out that the mess I was in had to do with rotation order and have solved it via a parent null taking over one of the rotation axis. Now I have another problem in that I'd much prefer to have a single controller for animating this part of the rig. Do you know any tricks to drive a parent child set of rotations via a single objects global rotation? see attached example scene. Further assistance.c4d
  15. Hey guys, Im a little confused with how normalised vectors should work. In this example I have a cube with some XPresso normalising its vector. When I rotate the cube (even just a tiny amount) along one of its axis, immediately the normal snaps to 1 or -1 depending on the direction rotated. Only when the other axis are non-zero do I get a useful result ie. nice smooth decimal gradient from -1 to 1. Why is this? Is there a way around it? Here's a very short screen capture of the issue: https://www.dropbox.com/s/mqii356j4ogev8n/Normalised vector issue.mov?dl=0 Thanks :)



C4D Cafe is the largest CINEMA 4D community. We provide facilities for discussion, showcasing and learning our favorite software :) Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, get your own private messenger, post status updates, manage your profile and much more. If you need to find solution to your problem or otherwise ask for help, Cafe is the right place.
  • Create New...