sketchucation logo sketchucation
    • 登入
    Oops, your profile's looking a bit empty! To help us tailor your experience, please fill in key details like your SketchUp version, skill level, operating system, and more. Update and save your info on your profile page today!
    ⚠️ Important | Libfredo 15.6b introduces important bugfixes for Fredo's Extensions Update

    Where lies the bug?

    已排程 已置頂 已鎖定 已移動 Developers' Forum
    24 貼文 8 Posters 3.1k 瀏覽 8 Watching
    正在載入更多貼文
    • 從舊到新
    • 從新到舊
    • 最多點贊
    回覆
    • 在新貼文中回覆
    登入後回覆
    此主題已被刪除。只有擁有主題管理權限的使用者可以查看。
    • thomthomT 離線
      thomthom
      最後由 編輯

      @unknownuser said:

      Tom,

      Sorry to pop up in this. I may have missed something.
      Do you wish to rotate and scale individual cubes (which is what I guess), or the whole selection?

      Whole selection. In regards to the RotaScale plugin: http://forums.sketchucation.com/viewtopic.php?f=180&t=19199
      The plugin works, in SU at least - but the problem is that VfSU doesn't read the transformation of the groups/components properly. So the transformation data needs to be converted into the same as it would if you'd use native SU tools.

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

      1 條回覆 最後回覆 回覆 引用 0
      • scottliningerS 離線
        scottlininger
        最後由 編輯

        Thom,

        Can you filter the weirdness down to a few lines of Ruby and post? Sounds like SketchUp is using one unused cell of the transform matrix to store some scale information. I have no idea why, but there's probably a legacy reason for it.

        • Scott Lininger
          SketchUp Software Engineer
          Have you visited the Ruby API Docs?
        1 條回覆 最後回覆 回覆 引用 0
        • P 離線
          Pout
          最後由 編輯

          we had a similar thingie with rotation an object in AutoCAD and then exporting it to VRML.
          I see if i can get a descent answer from a developer

          1 條回覆 最後回覆 回覆 引用 0
          • thomthomT 離線
            thomthom
            最後由 編輯

            http://forums.sketchucation.com/download/file.php?id=28725

            In this screenshot the two cubes are of the same definition. The large one is roated 45 degrees and scaled x2.0 manually.
            .transformation.to_a returns this for the manually rotated and scaled box:
            [1.4142135623731, -1.4142135623731, 0.0, 0.0, 1.4142135623731, 1.4142135623731, 0.0, 0.0, 0.0, 0.0, 2, 0.0, -16.3076205658699, 55.6776993060274, 0.0, 1.0]

            If I then RotaScale the small box to fit the large one .transformation returns this:
            [0.707106781186548, -0.707106781186548, 0.0, 0.0, 0.707106781186548, 0.707106781186548, -0.0, 0.0, 0.0, 0.0, 1.0, 0.0, -8.15381028293495, 27.8388496530137, 0.0, 0.5]

            Every value of the RotaScaled component is half of the manually scaled and rotated component.

            In Sketchup everything looks fine. But when I render RotaScaled groups/component with V-Ray they don't match.

            http://forums.sketchucation.com/download/file.php?id=28705&t=1

            What it looks like is that the scaling transformation I make is stored scaled down in the matrix and that this is indicated in the last (15th) array value. I've reported this to ASGVis.

            Question is, is this suppose to be like this?

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

            1 條回覆 最後回覆 回覆 引用 0
            • 1
            • 2
            • 2 / 2
            • 第一個貼文
              最後的貼文
            Buy SketchPlus
            Buy SUbD
            Buy WrapR
            Buy eBook
            Buy Modelur
            Buy Vertex Tools
            Buy SketchCuisine
            Buy FormFonts

            Advertisement