Page 1 of 2 12 LastLast
Results 1 to 15 of 17

Thread: Sketchup Models Loader

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Member
    Join Date
    Oct 2003
    Location
    Near Edinburgh
    Posts
    246

    Sketchup Models Loader

    Working on a sketchup model importer for Lightwave, limited to skp files made prior to version 2015. So far been working out how to get the hierarchy of components, groups and faces to load. Still working on the surfaces and textures, plus merging points.

    Depending on how well the model has been made in sketchup determines how many faces need flipping post import. The three models I downloaded from the 3D Warehouse all came in with minimal clean up required, a couple of bottles and vases on the worktops and the apples in the bowl.

    More updates as and when I get the next piece working.

    Regards

    Iain.
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	RevisionKitchen.jpg 
Views:	105 
Size:	247.4 KB 
ID:	133324   Click image for larger version. 

Name:	KraftMaid Makeover Kitchen.jpg 
Views:	116 
Size:	357.5 KB 
ID:	133325   Click image for larger version. 

Name:	KraftMaid Kitchen.jpg 
Views:	101 
Size:	289.7 KB 
ID:	133326  

  2. #2
    Nice, very interested to see how is progressing.

    I you need some test models let me know, I have some "nasty" building models which come in with many unwelded and flipped geometry after Sketchup export to OBJ.
    RAM-Studio
    WS - Dual Xeon E5-2698v4/128GB/Win10x64/x TitanX(M) + 2x GTX 1080Ti + GTX 1080
    My LWM Video Car Modeling Tutorial

  3. #3
    Any idea as to when we might be able to try out the plugin?

  4. #4
    Super Member spherical's Avatar
    Join Date
    Dec 2004
    Location
    San Juan Island
    Posts
    4,686
    This will be very welcome. I've been working with various skp models recently and the level of clueless modeling, combined with the Borked way that SketchUp works to begin with, I'd be way better off just modeling from scratch. Everything is double-sided, so most of the time there is no thickness to things like sheet metal legs, etc., it's all tripled and every little part is on a separate layer; sometimes hundreds of them. I use MergeTrigonsX to get most of the tris into quads, but it takes copying all of the layers into one or it sees no quads possible and nothing happens. It doesn't get them all, so the tedious process of merging polys manually ensues. Roughly half of the polys are flipped, once you turn off Double-sided. Unify Polys seems to be useless, but Reduce Polys sometimes cleans things up fairly well; it depends... upon what I don't know. After that, if you want to keep sections separately selectable for ease of working, you have to tediously re-separate them to their own layers or give them selection sets or textures, because one inadvertent point merge can ruin your whole day/week, as everything is connected when you least expect it. SketchUp is great for what it is, but the crappy modeling that it fosters is a bane. I commend you for taking on the task of converting/importing models made with it.
    Blown Glass · Carbon Fiber + Imagination

    Spherical Magic | We Build Cool Stuff!

    "When a man loves cats, I am his friend and comrade, without further introduction." - Mark Twain

  5. #5
    Member
    Join Date
    Oct 2003
    Location
    Near Edinburgh
    Posts
    246
    Thanks for the comments, I'm still some way off from having a plugin that I would be prepared to put out. I'll probably ask for some complicated models when I get further down my testing pipeline, I've still got to look at hidden objects and layers and dealing with textures and UV maps. Probably have to create the texture files from the image data in the sketchup file.

    spherical - Sketchup models really are a pain. I've been using some of the components that come with the latest version and they have caused me no end of problems with front and back faces. Trippling of the faces and using the front face points seems to get round most of the flipping problems. So far I have everything on one layer, the merge points could cause a problem due to the position of the points. I tried using the reduce poly tool with mixed results. Some objects were okay, others not. So I may have to look at multiple layers, merging and reducing polygons before having everything back in one layer.

    Regards

    Iain

  6. #6
    Member
    Join Date
    Oct 2003
    Location
    Near Edinburgh
    Posts
    246

    Update - UVs and textures

    I can now assign textures to surfaces and uv maps to the textures, thanks to support for the information on vmaps.

    Still got an issue with some of the faces being flipped, although looking in sketchup you can see which ones have been created back to front. I don't think that I can currently resolve that, though I will keep trying. Some issues with uvmaps from Sketchup. They use UVQ and STQ so you can end up with distortions, looking at what I can do with that, also not all maps have come in completely. Faces are created as ngons and the only tris are for faces with holes, all points get merged and all end up on a single layer. So still a work in progress.

    Iain
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	Kitchen.jpg 
Views:	68 
Size:	471.8 KB 
ID:	133624  

  7. #7
    looks very good Iain, keep up the good work and let us know on progress .
    RAM-Studio
    WS - Dual Xeon E5-2698v4/128GB/Win10x64/x TitanX(M) + 2x GTX 1080Ti + GTX 1080
    My LWM Video Car Modeling Tutorial

  8. #8
    Super Member JohnMarchant's Avatar
    Join Date
    Mar 2003
    Location
    Murcia, Spain
    Posts
    3,017
    Very interested Ian if it sorts out the flipped polys and such that comes out of an export from SU.
    Last edited by JohnMarchant; 04-29-2016 at 07:00 AM.
    Dell XPS 15
    15.6-inch (3840 x 2160) 4K 282ppi IPS LCD
    Intel i7 7700HQ 2.8GHz
    Windows 10 64Bit
    NVidia GeForce GTX 1050 Ti
    1TB SDD
    32Gb Ram

    LightWave 2019.03

    Very nice Laptop

  9. #9
    Registered User calilifestyle's Avatar
    Join Date
    Jun 2006
    Location
    cali, Santa Clarita
    Posts
    1,561
    Blog Entries
    4
    Oh man this is awesome. One question are able to keep the scale 1:1
    Ell no 'ta enamora' de mi, yo tampoco

  10. #10
    Member
    Join Date
    Oct 2003
    Location
    Near Edinburgh
    Posts
    246
    It respects the scale used to build the model, default in sketchup being inches, the necessary conversion is made to meters. There are five scales available and the plugin is coded to check which one is being used, the information being part of the model statistics.

  11. #11
    Super Member JohnMarchant's Avatar
    Join Date
    Mar 2003
    Location
    Murcia, Spain
    Posts
    3,017
    Quote Originally Posted by iain_r View Post
    It respects the scale used to build the model, default in sketchup being inches, the necessary conversion is made to meters. There are five scales available and the plugin is coded to check which one is being used, the information being part of the model statistics.
    Wow now im really looking forward to this.
    Dell XPS 15
    15.6-inch (3840 x 2160) 4K 282ppi IPS LCD
    Intel i7 7700HQ 2.8GHz
    Windows 10 64Bit
    NVidia GeForce GTX 1050 Ti
    1TB SDD
    32Gb Ram

    LightWave 2019.03

    Very nice Laptop

  12. #12
    Really itching to give this one a beta test!!

  13. #13
    Member
    Join Date
    Oct 2003
    Location
    Near Edinburgh
    Posts
    246
    I'm afraid you need to wait a bit longer, still having issues getting the polygons facing the correct way when they are correct in Sketchup. Faces that have been created back to front are even more problematic, some may be able to be corrected, but even in sketchup it's a manual process a lot of the time.

    Regards

    Iain

  14. #14
    Super Member JohnMarchant's Avatar
    Join Date
    Mar 2003
    Location
    Murcia, Spain
    Posts
    3,017
    Its because SU was made to maximise resources for models. Means its got some funky ways of making models and assigning Normal and UV maps. Its a PITA trying to sort out all the flipped polys and such. Its not like they follow some sort of regular pattern, like split up by inside and outside polys.

    A friend of mine told me that its great to work with but makes you a lazy modeler compared to normal 3d programs, because allot is done for you inside the software which is fine but trying to export is an issue.
    Dell XPS 15
    15.6-inch (3840 x 2160) 4K 282ppi IPS LCD
    Intel i7 7700HQ 2.8GHz
    Windows 10 64Bit
    NVidia GeForce GTX 1050 Ti
    1TB SDD
    32Gb Ram

    LightWave 2019.03

    Very nice Laptop

  15. #15
    Super Duper Member kopperdrake's Avatar
    Join Date
    Mar 2004
    Location
    Derbyshire, UK
    Posts
    3,134
    And there was me thinking I just had a crap workflow getting SU into LightWave! Good to hear it's bad, if that makes any sense.
    - web: http://www.albino-igil.co.uk - 2D/3D Design Studio -
    - PC Spec: Intel i9-7940X @3.1GHz | 64Gb | 2 x GeForce GTX 1080 Ti 11Gb | Windows 10 Pro -

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •