Jump to content

dast

Registered Member
  • Posts

    1,276
  • Joined

  • Last visited

  • Days Won

    65

Everything posted by dast

  1. dast

    R25 Expectations

    Well, I don't have much expectations, and am not really looking forward to R25, as I am happy with using my R20. But if they provide an Indie/Hobbyist license -without too much stripped down features- I might be tempted to reconsider and upgrade.
  2. dast

    EasyUV (R16-R21 only)

    Few months have past since last message. While no one reported being interested I have provided the plugin in the download section, free of charge (donations as token of support are always welcome and appreciated). I have spent some time working on the next iteration of the plugin. With version 1.4 I looked into implementing a bounding-box transform tool. As well as avoiding the need to manually apply an EasyUV Seam Tag to each object you want to unwrap. The tool will automatically assign the needed tag the first time a seam is applied. The reason for this is that I wanted to provide all the new changes into my Seamilar plugin, but EasyUV - being a smaller sibling - was the better starting point, as it provided for more experimentation with the existing code ... without breaking too many existing functionality. As mentioned earlier, this EasyUV plugin is merely focused on providing an easy way to unwrap your UVs. Therefore, few manipulation tools are present. It's bigger brother (Seamilar) is meant to provide those extra needed manipulation tools, and will soon see the additions made to EasyUV being added ... all depending on the feedback received on EasyUV. Note that the included documentation is for version 1.3, which required a license.
  3. Version 1.4 beta 1

    87 downloads

    EasyUV is a plugin (R16 - R21 for Windows and macOS) which focuses on easy unwrapping of UVs using a specialized Seam Tool for more information and latest news: https://www.core4d.com/ipb/forums/topic/104942-easyuv If you download, use, and appreciate this plugin, please consider donating using the "Tip Me" button. Every donation, great and small, is much appreciated and motivates me to keep providing plugin solutions for the community.
    Free
  4. Is it just a "reference", or would you suggest this for absolute Blender-beginners (not 3D-beginners)? I might be tempted to look into Blender if this encyclopedia does provide a helping hand. I know, there are quite enough tutorials available, but as you seem to like it, it might as well fit my needs too.
  5. Being a visual learner myself, that last quote should ring quite a lot of alarm bells and raise red flags ... definitely a scam-website 😉 ... I don't even have a six-pack in the fridge.
  6. ApplicationOutput("Tags found: @", tagcount); Yeah, the documentation isn't quite helpful as it should be for newbies, but after a while and with the help of some SDK examples you get there in the end. As for storing tags it depends what you want to do with it, but next to AtomArray you also can use maxon::BaseArray<BaseTag*> maxon::HashSet<BaseTag*> maxon::HashMap<... it all depends what manipulations you want to do with the list. To begin with, I mostly use BaseArray for simple lists. Additionally, prefer to use maxon's types (Int32, UInt, ...) over the standard types (int)
  7. dast

    INSYDIUM MeshTools

    That's why it is "sneak peek" I guess. I understood this to be a complete new plugin, not part of xParticles
  8. Everything between a StartUndo and EndUndo is a single undo (to the user). You can do as many AddUndo as you want, on a same or different object. To the user it is still a single undo operation. However, if you do a StartUndo-AddUndo-EndUndo for every of your 200 tags, then yes: the user will get 200 undo entries. But StartUndo-AddUndo-AddUndo-AddUndo-...-EndUndo is just a single undo operation.
  9. I have adjusted the Python script, as I noticed I performed an undo on the host object, instead of the tag itself. You will need to do the same in your C++ code.
  10. Since your R21 is listed as "unlimited" it will never expire. You can use R20 indefinitely, and R21 in theory as well (as long as you can regularly connect to MAXON's license server). As for S22, as I said before, this is a subscription version: it will stop working on 24/6.
  11. If you still have a perpetual license for R20 and R21 (not swapped for subscription, as Cairyn mentioned), then why not use these instead of a new subscription? Also, since S22 was a subscription only version, I don't think you'll be able to use that. The problem with R21 is that it needs to connect every 14 days to MAXON servers to "validate" its license. That's OK when you have a perpetual license, it should still be available. When MAXON's license servers are down (as seemed to have happened a while ago) and your R21 needs to connect to validate the license ... you're out of luck. With R20 you're safe as the old licensing scheme doesn't need to connect over the internet. As for your S24, I am pretty sure that once your subscription ends it won't start anymore.
  12. I am with you on preferring C++ over Python, but I cannot deny that Python is much easier to prototype a plugin. However, for debugging purposes or finding a problem in code I much prefer having a C++ plugin at hand. If I may I would like to point out some issues in your code. 1. In your CommandData::Execute you call "doc->StartUndo()" before obtaining the object you will be working with. This means that -potentially- the obtained object is nullptr and you exit the method. But without closing the started undo. Better to start the undo after having obtained the object. In your case you could even move all the undo stuff into your "RemoveTagsFromLeft" method, encapsulating the for loop. 2. AddUndo always need to be called BEFORE you actually perform the action, except when adding new objects. See the AddUndo documentation To get selected object(s) see BaseDocument::GetActiveObject and BaseDocument::GetActiveObjects To debug: right mouse click your project in Visual Studio, and select "properties" at the bottom of the popup-menu: Enter the location of the cinema4d executable. Optionally you can provide a "g_alloc=Debug" argument, which will provide allocation issues like memory leaks, etc. You can use "ApplicationOutput" to write to the CInema4D console window.
  13. Here is already a start: remove all texture tags except the last one. import c4d gTagType = c4d.Ttexture def GetTextureTagCount(obj): count = 0 if obj: while (obj.GetTag(gTagType, count)): count += 1 return count def RemoveTextureTagsButLast(obj): if not obj: print ('No object selected') return count = GetTextureTagCount(obj) if count == 0: print ('No texture tags') return doc.StartUndo() for i in range(0, count - 1): tag = obj.GetTag(gTagType) doc.AddUndo(c4d.UNDOTYPE_DELETE, tag) obj.KillTag(gTagType) doc.EndUndo() return def main(): if not op: print ('No object selected') return RemoveTextureTagsButLast(op) c4d.EventAdd() if __name__=='__main__': main() It only works on a single selected object, but you get the point. Now this script works with default Cinema4D materials and Cinema4D texture tags. Not sure how this looks like when Octane is used. Is only the Octane material different from the native one, or does an object also carry specific Octane texture tags? Honestly, I wouldn't know. If specific Octane texture tags are used, you can replace "c4d.Ttexture" with the pluginID of such Octane texture tag. EDIT: modified the script to perform the undo on the tag instead of the host object, for a correct redo.
  14. At first look this all can be done via simple scripting with Python. Usually you iterate over the tags of an object. With inbuilt tags this is not a problem, but I guess the Octane materials have a specific pluginID. Right now I am in a hurry, but could help you later, if needed.
  15. Sorry, cannot reproduce the problem. Tried with R21.207, render view works fine using Ctrl-R shortcut, or pressing the icon.
  16. dast

    RingLoop

    No! I mean the Python Console, which you open via shortcut shift-f10, then select the Python entry at the left.
  17. I am not sure anyone could give a proper answer here. My guess would be what the potential buyer would want to spend on this. Given that s/he might not be interested in the Vray additions. On the other hand having an R16 up to R20 (5 versions), and all these are perpetual license which DO NOT phone home every 14 days, that might become a rare, looked-after item in the (near) future. Who knows! Might become a "collectable"? (big bucks)
  18. dast

    RingLoop

    Does the Python Console show any error, or other message?
  19. Well, the moment you want to grab something out of that backup object ... you won't be able to, since you cannot expand it anymore (as long as the Python tag is active). There might be a simple solution for this, though. Let's say we modify the code to allow to expand IF the backup object is selected. That would prevent having to disable the Python tag when you need to get something out of that group. And still prevent expanding if you drop something into. Let me know if that would suit you. Happy to hear you're enjoying Dials as well.
  20. Not sure if this is what you're looking for, but If you add a Python tag to your "Bkup" object, and insert the following code, it will force to fold each time the object is unfolded. import c4d # Force folding the parent object if expanded. def main(): if op.GetObject().GetNBit(c4d.NBIT_OM1_FOLD): op.GetObject().ChangeNBit(c4d.NBIT_OM1_FOLD, c4d.NBITCONTROL_CLEAR) c4d.EventAdd() To allow the unfolding, you can temporarly disable the Python tag. NOTE: this will only work with the first Object Manager (you can open up to 4 of them), notice the bit about "OM1" in the code. If you need this for multiple Object Managers you need to duplicate the code for each Object Manager and change the OM1 to OM2, OM3, OM4 But I guess for 99.9% of the cases, just having one Object Manager is sufficient.
  21. Welcome to the community.
  22. Thanks for bringing this up. Hadn't really paid any attention to that. However, tested with R20 I don't see any issues. No double undo steps, no corrupted undo stack ... as far as I can see. And, honestly, the CallButton was just a placeholder for whatever the OP really wanted to do. At this point I still don't know if he/she wants the tags to be selected or the polygons. Hence I went for a quick mockup solution using the CallButton. If I was providing a "real" scripted solution I would probably go a complete different route, not using the CallButton. But you have a point bringing it up.
  23. Here is a first iteration. Without more information, that's all I am willing to spend time on for now. import c4d from c4d import gui byName = "test" # Daniel Sterckx 30-April-2021 # Iterate over polygon objects, # select polygons from polygon selection tag # that matches a given name def GetNextObject(obj): if obj == None: return None if obj.GetDown(): return obj.GetDown() while not obj.GetNext() and obj.GetUp(): obj = obj.GetUp() return obj.GetNext() def SelectPolygonSelections(obj, tagName): if obj and obj.IsInstanceOf(c4d.Opolygon): polyS = obj.GetPolygonS() polyS.DeselectAll() tag = obj.GetFirstTag() while tag: if tag.GetType() == c4d.Tpolygonselection and tag.GetName() == tagName: c4d.CallButton(tag, c4d.POLYGONSELECTIONTAG_COMMAND3) tag = tag.GetNext() return def main(): doc = c4d.documents.GetActiveDocument() obj = doc.GetFirstObject() if obj == None: return doc.StartUndo() while obj: if obj.IsInstanceOf(c4d.Opolygon): SelectPolygonSelections(obj, byName) obj = GetNextObject(obj) print("Done!") doc.EndUndo() c4d.EventAdd() # Execute main() if __name__=='__main__': main() For now you can provide the name in variable 'byName'. Here by default I have used "test". Currently it will iterate over ALL objects, selected or not. When creating a dialog you could provide the options to iterate over: - All objects - All selected objects - All selected objects and children And provide an entry field for the name to match. But as said, without more details of what you are looking for, that's it for me for now.
  24. It is still not clear if you just want to choose/select the polygon selection tag, or if you want to select the polygons within that tag.
  25. 1. What exactly are you looking the script to do? Select the polygon selection tag, or apply the selection stored in the tag -> thus selecting the polygons? 2. And are you looking for advice to write your own script, or are you looking for someone to provide you a complete script? If the former, then you would first iterate over all objects in your scene (recursively), check if it's a polygon object. Then you iterate over all tags of that object, check if the tag is of type 'polygon selection', and if it matches the required name. With that tag you then: or select the tag, or select the polygon (depending the answer of question 1) 3. Do you want this to be a single script? Since you seem to want the option to iterate over: - all objects in the scene - all selected objects in the scene If you opt for a single script you need a dialog to present the options.
×
×
  • Create New...

Copyright Core 4D © 2024 Powered by Invision Community