Jump to content


Regular Member
  • Content Count

  • Joined

  • Last visited

Community Reputation

5 Noble Beginner

About Myosis

  • Rank
    Cafe Ronin

Profile Information

  • First Name
  • Last Name

Cinema 4D Information

  • C4D Version
    19.024 Studio

Recent Profile Visitors

703 profile views
  1. @Rectro I remember you from the original post! Glad you're still interested! At the moment it only supports C4D naively. However you can still use it's function if your (renderer) has its own bake function, like Redshift, which has “BakeSet”. In this image we bake our Redshift render using the Redshift bake tool first, after that we can transfer it to a new model / new uv set using R.T.T. Image Hairs need to be converted to polygons first. As for your hairs, I'm not sure: If the Redshift "BakeSet" can bake them to their individual planes, then you can use this plugin to transform them to any “low poly” mesh like in the video. S22 might take a bit, but I do plan on it. Best, Myosis
  2. I continued the plugin, its in a new topic here: Thanks, Myosis
  3. Finally had time to release the plugin. I started this project a long time ago, and its still not perfect but i'm using it with almost every project. I'm not a scripting wonder, it took me way more time then I wanted, therefor its for sell, and not for free. Store Available for: R18, R19, R20, R21. Bake renders to textures Bake the render output directly onto a new mesh, or the same mesh. Because we are working with a boundary, anything that falls within will be baked. This even allows you to bake a displacement, or hairs as a texture. Full tutorial can be watched in this post or here on YouTube: Its a rather boring video sorry.. In this (3 minute) video make a bake from start to finish, and go over the pro's and con's. Functionalities are: Bake HDRI’s. Bake Hires to low res. Bake Hires onto itself (Can be done with no limitations). Bake Hires onto itself with new UV map. Low-res to new low-res with new UV layout. Displacement, hairs, textures. You get the point.. Limitations are: Not good with 90 degree corners. Low poly mesh has to be simple and smooth. Some hand clean up is necessary. (complex meshes) Small bug: The undo function (Ctrl+Z) doesn't work properly. So please work in a new scene when baking. Hi-res to low-res Even when the model does not have UV’s and is generically textured, you can simply transfer the data over to a new map. (In this scenario the Hi-res model had no uv’s, it had a cylindrical texture applied only repeating over the Y axis.) Redshift to texture You can do the same for any Redshift renders by baking them first onto itself with ‘Redshift bakeset’ and to a new model / new uv layout with ‘render to texture’. Hairs to texture You do need to convert it to pollies and use a non hair material, but it works great! Creating alphas is also not a problem. This scene and tutorial video will be included in the download. Transfer texture to new model An extreme example is to go from a cube to a sphere, obviously this would look very weird but it's possible. Therefore you can bake literally anything as a HDRI. Anything to a HDRI When you bake using a sphere as a boundary you can turn anything into an hdri. Let me know what you think. Thanks, Myosis PS: For those who signed up a year ago, a discount code is on its way.
  4. @Cairyn Thank you very much, it worked out great! You've helped me on numerous occasions (various topics) and I am very grateful. Been going down a rabbit hole on how to dynamically change the window size for when the group gets folded / unfolded. Figured this is a different topic so made a new thread for this: Cheers
  5. Hi, Preferably I don't want the user to resize the dialog window, but it doesn't seem possible when using a DLG_TYPE_ASYNC type dialog. I also gave up on trying to dynamically resize the dialog for when a group 'in the dialog' gets folded/unfolded, but that simply doesn't seem possible. Closest I came was closing it and reopening it in a different size. This worked to a certain extent but not without flaws. I got that idea from here So I stopped caring about the empty space when a group gets folded. But I want upon startup that the dialog “at least” goes back to its original shape. (the smallest it can be) Defaulth=0, defaultw=0 are only useful on the very first time opening. When the user resizes this c4d seems to prioritize this and saves it. So do I use RestoreLayout for this?
  6. Works very nice! I couldn't find an example of this online, I'm sure this will help others too, thank you very much! @Cairyn When I set the value of: flagSubgroupClosed = False To True it doesn't seem to be folded upon opening. Any idea what might cause that ? Side question: Tab groups, and quick tabs, don't work in a DLG_TYPE_ASYNC modal window, do they ? Cheers!
  7. Hi, Does anyone know why the button is not in/under the foldable subgroup? import c4d from c4d import gui class Fold(gui.GeDialog): def CreateLayout(self): self.SetTitle('') # create a quicktab self.GroupBegin(1011, c4d.BFH_SCALEFIT, 0, title = '') bc = c4d.BaseContainer() bc.SetBool(c4d.QUICKTAB_BAR, True) bc.SetString(c4d.QUICKTAB_BARTITLE, 'title') bc.SetBool(c4d.QUICKTAB_BARSUBGROUP, True) subgroup = self.AddCustomGui(122, c4d.CUSTOMGUI_QUICKTAB, '', c4d.BFH_SCALEFIT, 0, 0, bc) #foldable group ? self.GroupBegin(122, flags=c4d.BFH_SCALEFIT, cols=1, rows=1, title='', groupflags=0) self.AddButton(123, c4d.BFH_SCALEFIT, 0, 0, 'Button') self.GroupEnd() return True def main(): dlg = Fold() dlg.Open(c4d.DLG_TYPE_MODAL) if __name__=='__main__': main() c4d.EventAdd()
  8. @Cairyn Spent some time comparing the two and learned a bunch. I can see that I was pretty far-off. For some reason I thought I had to look at them individually. Your code makes a lot more sense, and works like a charm! I cannot thank you enough for helping me out with this, so I might give your patreon a try Thank you
  9. Once I cleared all empty selection tags, I'm left with 1 selection tag on each model, but I'm also I'm left with a bunch of texture tags. I want to remove all texture tags that are no longer referring to existing selection tags. But most of the texture tags still have a name in their selection "c4d.TEXTURETAG_RESTRICTION" (but that selection tag no longer exist). So I don't think I can use None in this case. My thought was to compare the names of each tag and remove if is doesn't match If I change the if not to, just if the scripts works reversed, I now remove all texture tags that are referring to existing selection tags. Hence the reason I tried if not, or else: but they both don't seem to be the solution. I hope I was able to explain myself clearly
  10. I'm now trying the same for texture tags I would like to remove them if there are no longer bound to an active selection tag. So I'm running along each tag looking for [c4d.TEXTURETAG_RESTRICTION] And if it contains the name of any active selection tag [c4d.ID_BASELIST_NAME] Code here: import c4d def iter_hierarchy(op): for tag in op.GetTags(): t = op.GetFirstTag() while t: if t.GetType() == c4d.Tpolygonselection: tagselection = t.GetBaseSelect() name = t[c4d.ID_BASELIST_NAME] print name if tag.CheckType(c4d.Ttexture): texname = tag[c4d.TEXTURETAG_RESTRICTION] if not name in texname: doc.AddUndo(c4d.UNDOTYPE_DELETE, tag) tag.Remove() t = t.GetNext() print 'run new tag' for child in op.GetChildren(): iter_hierarchy(child) def main(): for op in doc.GetObjects(): iter_hierarchy(op) c4d.EventAdd() main() If anyone can see the flaw, it would be the final piece to the puzzle for me! My guess is that I'm doing something wrong in the texture tag restriction ?
  11. Oops faceplam, thank you! Works perfect now, super happy
  12. It should be something like this? for tag in op.GetTags(): if tag.CheckType(c4d.Tpolygonselection): tagselection = tag.GetBaseSelect() tagselection.GetCount() print tagselection.GetCount() if tagselection.GetCount()>= 0: doc.AddUndo(c4d.UNDOTYPE_DELETE, tag) tag.Remove() else: return Again I'm not very experienced. At the moment its removing all tags. It isn't reading the 0 part properly?
  13. @Cairyn Yes if the GetCount is 0 I would like to remove the tag But I can't figure out how to write that particular line
  14. @Cairyn Is it possible you could show me an example of how to implement this in a small script ? I managed to see the poly count in the console with your advice: tagselection = tag.GetBaseSelect() tagselection.GetCount() print tagselection.GetCount() But I'm not sure how to continue the script if it reads 0
  15. @Cairyn That sounds interesting! Not that experienced yet, but will try to puzzle a bit more with the info you gave me, thanks
  • Create New...