sketchucation logo sketchucation
    • Login
    πŸ›£οΈ Road Profile Builder | Generate roads, curbs and pavements easily Download

    Information in the dictionary = huge filesize

    scheduled pinned locked moved Developers' Forum
    9 Posts 5 Posters 678 Views 5 Watching
    loading-more-posts
    • oldest-to-newest
    • newest-to-oldest
    • most-votes
    reply
    • reply-as-topic
    guest-login-reply
    deleted-message
    • P Offline
      Pout
      last edited by

      When adding information in the dictionary of Sketchup entities the filesize is growing very fast.
      I have added information to all entities of a 25Mb model and this results in a 75Mb model...

      Does Su not handle well that information or is this normal?

      one-reply-to-this-post last-reply-time reply quote 0
      • R Offline
        remus
        last edited by

        Depends how much info your adding, but 50mb certainly sounds a lot.

        Any more details on what your doing?

        http://remusrendering.wordpress.com/

        one-reply-to-this-post last-reply-time reply quote 0
        • thomthomT Offline
          thomthom
          last edited by

          What data and how many entities?

          Thomas Thomassen β€” SketchUp Monkey & Coding addict
          List of my plugins and link to the CookieWare fund

          one-reply-to-this-post last-reply-time reply quote 0
          • P Offline
            Pout
            last edited by

            the amount of entities is alot: 350K
            the data is simple:
            the name of the original color of the entity (like listed in the materials list)
            and one other short piece of text

            one-reply-to-this-post last-reply-time reply quote 0
            • Chris FullmerC Offline
              Chris Fullmer
              last edited by

              Sounds like a bug. I don't think it should be so much. Perhaps an issue with the code where you add the text once to the first entitiry, twice tot he second, three times to the third, etc?

              Chris

              Lately you've been tan, suspicious for the winter.
              All my Plugins I've written

              one-reply-to-this-post last-reply-time reply quote 0
              • thomthomT Offline
                thomthom
                last edited by

                Got a sample model and code snippet?

                Thomas Thomassen β€” SketchUp Monkey & Coding addict
                List of my plugins and link to the CookieWare fund

                one-reply-to-this-post last-reply-time reply quote 0
                • AdamBA Offline
                  AdamB
                  last edited by

                  Sounds completely reasonable to me.

                  Filesize increase is 50000000
                  Number of entities 350000

                  So each dictionary entry is 142 bytes which is completely believable.

                  Developer of LightUp Click for website

                  one-reply-to-this-post last-reply-time reply quote 0
                  • thomthomT Offline
                    thomthom
                    last edited by

                    In the SKP file format each attribute is stored in a UTF-16 datablock which adds extra overhead for each attribute.

                    Thomas Thomassen β€” SketchUp Monkey & Coding addict
                    List of my plugins and link to the CookieWare fund

                    one-reply-to-this-post last-reply-time reply quote 0
                    • P Offline
                      Pout
                      last edited by

                      i don't think there is a bug since i can easily read the data from the dictionary.
                      I don't have a example at hand (since they are all way to big)
                      But this is what is added to each entity :

                      e.set_attribute 'libraryname', 'suid', variable (number)
                      e.set_attribute 'libraryname', 'mat_or', name of the original material (text)
                      when a face;
                      e.set_attribute 'libraryname', 'matback_or', name of the original material (text)
                      e.set_attribute 'libraryname', 'typestatus', name of a material (text)
                      
                      one-reply-to-this-post last-reply-time reply quote 0
                      • 1 / 1
                      • first-post
                        last-post
                      Buy SketchPlus
                      Buy SUbD
                      Buy WrapR
                      Buy eBook
                      Buy Modelur
                      Buy Vertex Tools
                      Buy SketchCuisine
                      Buy FormFonts

                      Advertisement