Create UV Templates directly from Poser



  • I can now the script has finished, just finished this minute. Here is the output you asked for.

    Loading UV from OBJ file "E:\Runtime\Geometries\Lwanmtr\DPMotors\CV1.obj"
    Counted 529422 facet edges
    Counted 14802 seam edges
    Read 759466 lines from file
    Num Verts = 266794 (266794)
    Num TVerts = 229461 (229461)
    Num Norms = 0 (0)
    Num TSets = 1044228
    Num Elems = 262724
    Num Sets = 1044228
    Num Seams = 14802
    Num Sections = 0
    Num Groups = 17
    Main
    LFWheel
    RFWheel
    RearWheels
    Trunk
    SColumn
    SWheel
    Gas
    Brake
    DrivFrontDoor
    PassFrontDoor
    DrivRearDoor
    PassRearDoor
    DrivSeat
    DrivBack
    PassSeat
    PassBack
    Num Materials = 59
    CV-Int-DummyLightPlastic, UDIM=1001
    CV-Int-DummyLight, UDIM=1001
    CV-Chrome, UDIM=1002
    CV-Body-RearClipStrip, UDIM=1003
    CV-Body-FrontClipStrip, UDIM=1003
    CV-Body-Side, UDIM=1003
    CV-Int, UDIM=1001
    CV-Black, UDIM=1004
    CV-Int-Trunk, UDIM=1001
    CV-ChromeBlack, UDIM=1005
    CV-Body-Glass, UDIM=1003
    CV-Body-HoodInner, UDIM=1003
    CV-Logo-Clear, UDIM=1006
    CV-Logo-Color, UDIM=1006
    CV-BlackPlastic, UDIM=1007
    CV-Body-Mirror, UDIM=1003
    CV-Body-Light-Head, UDIM=1003
    CV-Body-Light-HLite2, UDIM=1003
    CV-Body-Light-Orange, UDIM=1003
    CV-Body-Light-Cover, UDIM=1003
    CV-Body-Light-Int, UDIM=1003
    CV-Rubber, UDIM=1008
    CV-Body-Door-WinTrim, UDIM=1003
    CV-Dash-Buttons, UDIM=1009
    CV-Dash-Vents, UDIM=1009
    CV-Dash-InstNeedle, UDIM=1009
    CV-Dash-Instrument, UDIM=1009
    CV-Dash-Main, UDIM=1009
    CV-Dash-Main-2, UDIM=1009
    CV-Dash-DK, UDIM=1009
    CV-Seat, UDIM=1010
    CV-GasTank, UDIM=1011
    CV-Body-Bottom, UDIM=1003
    CV-Body-Light-Red, UDIM=1003
    CV-Dash-Env, UDIM=1009
    CV-Dash-CDDisplay, UDIM=1009
    CV-Body, UDIM=1003
    CV-Dash-InstGlass, UDIM=1009
    CV-Tire-Lores, UDIM=1012
    CV-Tire-BrakeDisc, UDIM=1012
    CV-Tire-Hubcap, UDIM=1012
    CV-Tire-Rim, UDIM=1012
    CV-Tire-Rim-Edge, UDIM=1012
    CV-Body-TrunkChrome, UDIM=1003
    CV-Body-TrunkInner, UDIM=1003
    CV-Body-Light-BULite, UDIM=1003
    CV-Body-TrunkRubber, UDIM=1003
    CV-SColumnLever, UDIM=1013
    CV-SColumnLeverHandle, UDIM=1014
    CV-SColumnDGrey, UDIM=1015
    CV-SColumn, UDIM=1016
    CV-SWheel, UDIM=1017
    CV-SWheelButton, UDIM=1018
    CV-Int-Pedals, UDIM=1001
    CV-Int-Door, UDIM=1001
    CV-Body-Door-Inner, UDIM=1003
    CV-Int-Door2, UDIM=1001
    CV-Body-MirrorBody, UDIM=1003
    CV-Body-Door-Trim, UDIM=1003
    UV Range = ((0.0, 0.99999999), (0.0, 0.99999999))
    0 CV-Int-DummyLightPlastic (255, 0, 0, 255)
    1 CV-Int-DummyLight (255, 25, 0, 255)
    6 CV-Int (255, 155, 0, 255)
    8 CV-Int-Trunk (255, 207, 0, 255)
    53 CV-Int-Pedals (255, 0, 155, 255)
    54 CV-Int-Door (255, 0, 129, 255)
    56 CV-Int-Door2 (255, 0, 77, 255)
    UVTemplate "CV1UV_1001.png" for: ['CV-Int-DummyLightPlastic', 'CV-Int-DummyLight', 'CV-Int', 'CV-Int-Trunk', 'CV-Int-Pedals', 'CV-Int-Door', 'CV-Int-Door2']
    2 CV-Chrome (255, 51, 0, 255)
    UVTemplate "CV1UV_1002.png" for: ['CV-Chrome']
    3 CV-Body-RearClipStrip (255, 77, 0, 255)
    4 CV-Body-FrontClipStrip (255, 103, 0, 255)
    5 CV-Body-Side (255, 129, 0, 255)
    10 CV-Body-Glass (250, 255, 0, 255)
    11 CV-Body-HoodInner (224, 255, 0, 255)
    15 CV-Body-Mirror (121, 255, 0, 255)
    16 CV-Body-Light-Head (95, 255, 0, 255)
    17 CV-Body-Light-HLite2 (69, 255, 0, 255)
    18 CV-Body-Light-Orange (43, 255, 0, 255)
    19 CV-Body-Light-Cover (17, 255, 0, 255)
    20 CV-Body-Light-Int (0, 255, 8, 255)
    22 CV-Body-Door-WinTrim (0, 255, 60, 255)
    32 CV-Body-Bottom (0, 190, 255, 255)
    33 CV-Body-Light-Red (0, 164, 255, 255)
    36 CV-Body (0, 86, 255, 255)
    43 CV-Body-TrunkChrome (95, 0, 255, 255)
    44 CV-Body-TrunkInner (121, 0, 255, 255)
    45 CV-Body-Light-BULite (146, 0, 255, 255)
    46 CV-Body-TrunkRubber (172, 0, 255, 255)
    55 CV-Body-Door-Inner (255, 0, 103, 255)
    57 CV-Body-MirrorBody (255, 0, 51, 255)
    58 CV-Body-Door-Trim (255, 0, 25, 255)
    UVTemplate "CV1UV_1003.png" for: ['CV-Body-RearClipStrip', 'CV-Body-FrontClipStrip', 'CV-Body-Side', 'CV-Body-Glass', 'CV-Body-HoodInner', 'CV-Body-Mirror', 'CV-Body-Light-Head', 'CV-Body-Light-HLite2', 'CV-Body-Light-Orange', 'CV-Body-Light-Cover', 'CV-Body-Light-Int', 'CV-Body-Door-WinTrim', 'CV-Body-Bottom', 'CV-Body-Light-Red', 'CV-Body', 'CV-Body-TrunkChrome', 'CV-Body-TrunkInner', 'CV-Body-Light-BULite', 'CV-Body-TrunkRubber', 'CV-Body-Door-Inner', 'CV-Body-MirrorBody', 'CV-Body-Door-Trim']
    7 CV-Black (255, 181, 0, 255)
    UVTemplate "CV1UV_1004.png" for: ['CV-Black']
    9 CV-ChromeBlack (255, 233, 0, 255)
    UVTemplate "CV1UV_1005.png" for: ['CV-ChromeBlack']
    12 CV-Logo-Clear (198, 255, 0, 255)
    13 CV-Logo-Color (172, 255, 0, 255)
    UVTemplate "CV1UV_1006.png" for: ['CV-Logo-Clear', 'CV-Logo-Color']
    14 CV-BlackPlastic (146, 255, 0, 255)
    UVTemplate "CV1UV_1007.png" for: ['CV-BlackPlastic']
    21 CV-Rubber (0, 255, 34, 255)
    UVTemplate "CV1UV_1008.png" for: ['CV-Rubber']
    34 CV-Dash-Env (0, 138, 255, 255)
    35 CV-Dash-CDDisplay (0, 112, 255, 255)
    37 CV-Dash-InstGlass (0, 60, 255, 255)
    23 CV-Dash-Buttons (0, 255, 86, 255)
    24 CV-Dash-Vents (0, 255, 112, 255)
    25 CV-Dash-InstNeedle (0, 255, 138, 255)
    26 CV-Dash-Instrument (0, 255, 164, 255)
    27 CV-Dash-Main (0, 255, 190, 255)
    28 CV-Dash-Main-2 (0, 255, 216, 255)
    29 CV-Dash-DK (0, 255, 242, 255)
    UVTemplate "CV1UV_1009.png" for: ['CV-Dash-Env', 'CV-Dash-CDDisplay', 'CV-Dash-InstGlass', 'CV-Dash-Buttons', 'CV-Dash-Vents', 'CV-Dash-InstNeedle', 'CV-Dash-Instrument', 'CV-Dash-Main', 'CV-Dash-Main-2', 'CV-Dash-DK']
    30 CV-Seat (0, 242, 255, 255)
    UVTemplate "CV1UV_1010.png" for: ['CV-Seat']
    31 CV-GasTank (0, 216, 255, 255)
    UVTemplate "CV1UV_1011.png" for: ['CV-GasTank']
    40 CV-Tire-Hubcap (17, 0, 255, 255)
    41 CV-Tire-Rim (43, 0, 255, 255)
    42 CV-Tire-Rim-Edge (69, 0, 255, 255)
    38 CV-Tire-Lores (0, 34, 255, 255)
    39 CV-Tire-BrakeDisc (0, 8, 255, 255)
    UVTemplate "CV1UV_1012.png" for: ['CV-Tire-Hubcap', 'CV-Tire-Rim', 'CV-Tire-Rim-Edge', 'CV-Tire-Lores', 'CV-Tire-BrakeDisc']
    47 CV-SColumnLever (198, 0, 255, 255)
    UVTemplate "CV1UV_1013.png" for: ['CV-SColumnLever']
    48 CV-SColumnLeverHandle (224, 0, 255, 255)
    UVTemplate "CV1UV_1014.png" for: ['CV-SColumnLeverHandle']
    49 CV-SColumnDGrey (250, 0, 255, 255)
    UVTemplate "CV1UV_1015.png" for: ['CV-SColumnDGrey']
    50 CV-SColumn (255, 0, 233, 255)
    UVTemplate "CV1UV_1016.png" for: ['CV-SColumn']
    51 CV-SWheel (255, 0, 207, 255)
    UVTemplate "CV1UV_1017.png" for: ['CV-SWheel']
    52 CV-SWheelButton (255, 0, 181, 255)
    UVTemplate "CV1UV_1018.png" for: ['CV-SWheelButton']



  • This is a direct capture of the preview. If you wanted a render, it might take a while, depending on what detail you wanted.
    0_1508420132250_68479687.png



  • I figured I'd try putting the above template over the main body to see if it was the right one. Dunno about you, but I think it looks like the right one, as some areas match up, don't they?
    0_1508420314257_64876541.png



  • Though the map is stretched, so it would make it tricky to make the livery for it, but I could give it a go, if it was cleaner.



  • @Glen85 Ah! I see, didn't notice before, this is a seriously detailed model. Over a million sets and tsets, 500k+ facet edges, no wonder!

    So, the UV template separation is doing what it was supposed to via the material names, but the names don't eliminate all the overlaps.

    The most important thing to note with the template as texture, is if the facet edges appear in the same place as where the edges show if you turn on Lit Wireframe or Hidden Line in the display mode for the figure. It certainly looks right, there. As correct as the supplied template was totally wrong.



  • Told you! ;)



  • It's an excellent product, just needs decent templates! The guy who made all those material sets seems to have removed everything, which is really sad. He even made modern equipment to go with the car, like a laptop etc! I'd absolutely love that kit and the CHP livery for it, then I could get on with Annie's police pinup! ^_^



  • @Glen85 the script is definitely doing it's job. We just need to get the proper separations happening. I don't think there is any stretching in the UV's. The script doesn't work in a way that distorts anything. The appearance of stretching is just overlapping templates which need to be separated to a different map. The only way that's going to happen is manually telling the script which materials go on which UDIM pages, and the material names are not quite enough information to go on.

    So, we're back to the need for a proper component of a full UV mapping utility, which is user selection and assignment of materials to UDIM regions. GUI ahoy!

    I should make it clear that this is one of those teeth pulling moments, where I'm absolutely convinced I need to do something, but live in fear of the unknown size or duration of the torture I'm about to inflict upon myself. The first time I sat down to try and convert one of Ockham's really useful Tkinter scripts into wxPython, so I could run it on macOS took months of research until I happened to stumble across a script which did something almost like what I needed to translate, and I realised I'd found my Rosetta Stone! Everything started to fall into place. That time it was just my own need driving the progress. Now, at least, I can demonstrably help solve someone else's problem, and do it within Poser, so the goals are a lot clearer.

    Anyway, TL;DR. Off to push my head into the wxGUI blender. Err, Python's mouth... [Disclaimer: No herpetologists or pixels will be harmed during this exercise. (Much)]



  • Lol, you do make me laugh! Well, I would offer my services, but I know literally nothing whatsoever about the technical stuff you just mentioned... so if you want a cuppa tea...?

    Regarding the material names, this has given maps of different materials. Prime example is that the main body and the mirrors are both clearly present on that map, whereas only the main body is needed. If the script only put the main body template there, the mirrors wouldn't be there at all. I don't know if that's what you're talking about, or if the script might have missed something, but yeah.

    I wonder if you can make a simple 'invisible' material, have it applied to all other parts of the car, then tell the script to ignore any parts with the material 'invisible' or whatever?

    Maybe I'm making no sense, in which case, I told you I know sod all about sod all, lol! :P



  • Also, the main body and the doors, while sharing the same material, are different objects, in and of themselves... for example.