Creating a Mesh from Scratch with Python

Поделиться
HTML-код
  • Опубликовано: 21 окт 2024

Комментарии • 43

  • @exhilex
    @exhilex Год назад +9

    Python with blender is extremely powerful and let me tell you that you are doing a wonderful job taking all the complex documentation stuff and bringing to the audience such beginner friendly tutorials!

    • @CGPython
      @CGPython  Год назад +1

      I'm delighted that you think that way about my work! 😊
      Thank you!

  • @commonpike
    @commonpike 11 месяцев назад +4

    Perfect tutorial. Speed is good, simple enough. Thank you.
    Personally, I could do without the music :-) While toying along, I'm pausing all the time, so I'm not enjoying the music anyway.

    • @CGPython
      @CGPython  11 месяцев назад

      You are welcome! ❤️
      Thank you for the feedback about the music!

  • @mind_of_a_darkhorse
    @mind_of_a_darkhorse Год назад +1

    Great tutorial! I just started to use List Comprehension and it sure simplifies things, but is a little hard to get use to after doing it the old way! LOL! Keep up the great work!

    • @CGPython
      @CGPython  Год назад +1

      Thanks! 😊
      You can do it! I also had a hard time when I was just starting to use List Comprehension.
      You just need to keep practicing, and it will become second nature to you. 💪

  • @williamanim4267
    @williamanim4267 Год назад +1

    i really love your content man, its priceless!!
    Thank you so much for share it with the comunnity ^-^

    • @CGPython
      @CGPython  Год назад

      I appreciate that! ❤️
      I am glad you like it

  • @sj_life_and_science
    @sj_life_and_science 2 месяца назад

    Great video thank you

  • @RomboutVersluijs
    @RomboutVersluijs 3 месяца назад

    Nice! Inwas looking at an API from a 3d foliage provider. They have modules for their own models and I got it working exporting obj files. Now using this to make blender models directly in blender will be way faster. No need for export and than import

  • @exhilex
    @exhilex Год назад

    May this video reach more people

  • @RomboutVersluijs
    @RomboutVersluijs 3 месяца назад

    Did you get those face indices by actativating the overlay for that. Was wondering how your got those numbers

    • @CGPython
      @CGPython  3 месяца назад

      You need to enable the Developer Extras in the preferences
      Here is what I did
      ruclips.net/video/9WnNRD8viX8/видео.html

  • @mepro3432
    @mepro3432 Год назад +1

    Ur the best tutorial vd incould say frfr

  • @Анастасия-ж5у1г
    @Анастасия-ж5у1г 6 месяцев назад

    Thanks for the new information! Please tell me if the channel has content on programming tools such as bpy.ops.mesh.loopcut_slide or loop tools?

    • @CGPython
      @CGPython  6 месяцев назад

      Happy to help
      At this point it does not have that content

  • @RomboutVersluijs
    @RomboutVersluijs 3 месяца назад

    I was wondering if there would be a speedup if we use bumpy. This is just a small model. I'm thinking of using it to generate foliage. I've got the data in different kind of arrays. It's basically on big list, so I need to first make an array of 3. Wonder if nunoy will be faster

    • @CGPython
      @CGPython  3 месяца назад

      by "bumpy" and "nunoy" you mean NumPy, right?
      NumPy would make things faster

  • @davedumas0
    @davedumas0 Год назад

    it has a hard time with geo nodes but if i feed it your "helper code" first and it does much better it only had a hard time with the names of the geo nodes so i just put a dict with a list of a bunch in the code before i post to GPT and it does much better

  • @RomboutVersluijs
    @RomboutVersluijs 3 месяца назад

    I'm confused why you run a sub for loop for those fave_vert_indices. It's basically a list of 4 items. So why do you run another for loop on each. Each item in that vert_ind8ces, only consist of 1 item, a single number. Or are you getting the coordinates of each face vertices. Not sure how the code reads that from only using index. I guess these are not random names, they are actually bmesh names for the attributes

    • @CGPython
      @CGPython  3 месяца назад

      At this point I am going to guess you watched the rest of the video where we add more items to the fave_vert_indices.
      We need to define each face using the index of the verts.

  • @driftwood-f4p
    @driftwood-f4p Год назад

    I want to know how to do procedural modeling, such as creating a custom shape and then adjusting the width and height, or shape.

  • @mingothemongo4466
    @mingothemongo4466 Год назад

    such good stuff!

  • @TarasFTR
    @TarasFTR Год назад

    I am writing add ons with geometry node. How knows, how to read object/mesh from node input and how to set object/mesh in node output? I can't find anything

    • @CGPython
      @CGPython  Год назад

      Hello
      I'm not 100% sure what you are asking.
      Are you asking how you can use the Object Info node and select a mesh?
      Do you have some sample code or maybe a RUclips video link that shows what you are asking about or trying to do?
      If you want to send me a link, you can find me on Twitter and send me the link there @cgpython
      IIRC RUclips doesn't allow links in comments

  • @RomboutVersluijs
    @RomboutVersluijs 3 месяца назад

    Which video is the follow-up for this one?

    • @CGPython
      @CGPython  3 месяца назад

      It is this one ruclips.net/video/aSkgwf0SX_k/видео.html
      Thank you for pointing this out!
      I forgot to link it 🫠

  • @davedumas0
    @davedumas0 Год назад

    have you attempted to play with chat-GPT for writing scripts for blender kinda fun!

    • @CGPython
      @CGPython  Год назад

      Hey,
      Yes, I have, it is very cool!
      But I had mixed luck in getting it to do more complex things.
      A person without any Python knowledge might have a bit of trouble getting some scripts to work.
      When 95% of the script is correct, getting that 5% might be very challenging if you don't know what to ask to fix the issue.

    • @davedumas0
      @davedumas0 Год назад

      yeah im having the same issue but i got a script set up with a bunch of helper functions and i post that to give the api context of what im going it still gets stuff wrong mostly because the blender im using came out after 2021 so commands are a little different
      @@CGPython

  • @dev.ashesh
    @dev.ashesh Год назад

    how to read a binary file that contains an object and create it to blender ?

    • @CGPython
      @CGPython  Год назад

      Hello,
      What is the format of your binary file?

    • @dev.ashesh
      @dev.ashesh Год назад

      @@CGPython .TMB file and .THM file..

    • @CGPython
      @CGPython  Год назад

      sorry, I have not worked with this file formats.
      Looks like this might work with tmb files
      github.com/0ceal0t/BlenderAssist#tmb-and-pap-files

  • @wissammmax
    @wissammmax Год назад

    thanks alot for your beneficial content

  • @curlyflipper2020
    @curlyflipper2020 Год назад +1

    Hey thanks for the tut u made. I was wonder if you could do me a flavor ? I tried doing some research on how to get the best score 'python bge ' , however it's too complicated to make out with how to make use of any of it . Below this is the code i that im using . I have some ideas on how to add a best score in this fashion , Scene 1 save current score , Scene 2 load current score , and Scene 3 load best score . However I was wondering if you could make some sense how to do this ?
    import bge
    from bge import logic
    path = logic.expandPath('//')
    def save():
    cont = bge.logic.getCurrentController()
    own = cont.owner
    info = own ['Text']
    file = open(path+'The_Score.txt', 'w')
    file.write(str(info))
    def load():
    cont = bge.logic.getCurrentController()
    own = cont.owner
    info = own ['Text']
    file = open(path+'The_Score.txt', 'r')
    line = file.readline()
    print(line)
    own ['Text'] = int(line)

    • @CGPython
      @CGPython  Год назад +1

      Hello!
      I'm not too familiar with BGE, so I can't really help you here, sorry.
      It does look like valid Python code, but it is not closing the file after opening it for reading or writing.
      www.w3schools.com/python/ref_file_close.asp
      Consider using the with statement that will automatically close the file
      www.freecodecamp.org/news/with-open-in-python-with-statement-syntax-example/