Page 1 of 11 123 ... LastLast
Results 1 to 40 of 401
  1. #1

    Default Blender 2.57 ASE export

    ASE Export Script
    MCampagnini (http://code.google.com/p/ase-export-vmc/)
    Version 2.5


    Videos


    Installation
    • Download and extract the ASE Export Script.
    • In Blender, File / User Preferences.
    • Go to the Add-On Tab.
    • Install Add-On, select the extracted python script.
    • Click Save as Default to enable the script every time Blender loads (optional).


    You will find a new export option in File / Export called Ascii Scene Export (.ase). If you do not see the script in the export menu after following the installation instructions, open the Add-On tab and find the script under Import-Export: ASCII Scene Exporter. Be sure that it is enabled by checking the box next to the add-on name. Contact me on my website if you still have problems exporting.

    Mesh Requirements
    • All non-collision geometries must be UV unwrapped.
    • All non-collision geometries must have a material applied.


    Optional
    • Mesh may have more than one material.
    • Mesh may have more than one UV texture and/or a lightmap uv.
    • Mesh may be assigned as a collision object.
    • Mesh may have more than one collision object to determine collision borders.
    • Mesh may be assigned smoothing groups.
    • Smart people will watch the demonstration video on my website.


    Collision Objects
    Assign a mesh as a collision object by prefixing each object name with UCX_NAME, where NAME can be anything you would like (case-insensitive).

    Smoothing Groups
    Assign smoothing groups by edge selecting the border of the faces you want assigned to a smoothing group, press ctrl+e and mark sharp. Any face group separated with sharp edges will be assigned a smoothing group.

    Vertex Painting
    Apply vertex painting in Blender as normal, be sure that you have at least two uv texture slots. This is not a technical limitation, but due to time constraints I left the vertex painting code inside of a conditional that requires two uv textures. In order to view your vertex painting in UDK you will have to import and set up your materials correctly within UDK.

    Change Log

    Version 2.01a to 2.5
    • Performance adjustments and code refactoring
    • Use Submaterials toggle to give control on how to export materials
    • Allow multiple materials to toggle whether a geometry node can have more than one material assigned
    • The additions of these new features allow the ASE file to be read by the Id Tech 4 engine and other technologies


    Version 2.01 to 2.01a
    • Fixed my vertex painting fix


    Version 2.00 to 2.01
    • Fixed scale bug that prevented proper scaling when exporting.
    • Fixed vertex painting 'MeshLoopColor' object has no attribute 'color1'.
    • Made default scale 1:1 (1 foot in Blender is 1 foot in UDK, depending on Blender grid setup).
    • Cleanup.

    Version 1.41 to 2.00
    • Upgraded for Blender 2.63a.
    • Fixed smoothing groups (broken in 2.62).
    • Extra options in the export window.
    • Removed origin recentering.

    Version 1.4 to 1.41
    • Added an export option to recalculate normals.

    Version 1.35 to 1.4
    • Added vertex painting support. Requires two uv textures.

    Version 1.3 to 1.35
    • Fixed a bug causing ugly output when over 32 smoothing groups were assigned
    • Recoded a small portion of the script to remove complications when assigning more than 150 smoothing groups.
    • Fixed a crash by adding in a bpy.ops.mesh.reveal before calculating mesh data. Any hidden parts of your mesh will be made visible before performing the export.


    Download at http://code.google.com/p/ase-export-vmc/
    Last edited by MCampagnini; 07-31-2012 at 09:07 PM.

  2. #2

    Default

    While I currently making levels with the UT 3 editor, I would like to say "thank you very much" for taking the time to update this script!

    I was happy when 2.57 was released, but sort of bummed because there was no .ASE exporter that worked with it. Now that's changed and I can charge forward knowing my time won't be wasted making models that couldn't be exported.

    I am constructing a Blender to Unreal tutorial page and I updated my current Exporting To Unreal page with your script.

    In my testing (and limited experience), it seems like you have to enter the file extension ".ase" in order for it to properly work?

    It will be great when you can implement multiple UVs for light mapping.

    Since I am a beta tester at heart, I wonder if the following is possible, some time in the future?

    • Not requiring a material/image/UV to be assigned. I only say this for collision models (though it's reasonably easy to add these since they don't have to be precise).
    • To not triangulate the mesh (assuming the editor will triangulate it for you)? I ask this so the model can still retain it's original quads.

    I also tested to see if Vertex Painting works and it does, so that's nice. The only thing I am not familiar with is "smoothing" groups, but I will test that some more tonight.

    Thanks again for your time and effort. Sorry for the long-winded post, but I am excited that I can now get to "work" with Blender and the Unreal editor.

  3. #3

    Default

    I just updated the script about 20 minutes ago so that any material not assigned to a face will not be added - in addition it requires a unique texture image for each material. The reason for this was to make sure people only export out ASE's without extra & unused materials/textures. Updates will keep rolling out, we have to get Blender deeper into the game development pipeline!

    In a future update i'll make it detect the UCX_Collision mesh name and void the material / texture requirements.

    As far as mesh triangulation goes, ill see about setting a toggle when exporting.

    Smoothing groups might be a time sink, i've talked with some people about it...maybe there is a workaround. Besides, exporting multiple uv maps correctly is more important!

    --edit: and yes it needs a *.ase name, if you save your .blend it should have [project_name].ase already filled out.

    Glad I helped out someone,

    MC
    Last edited by MCampagnini; 04-19-2011 at 12:50 AM.

  4. #4

    Default

    Quote Originally Posted by MCampagnini View Post
    I just updated the script about 20 minutes ago so that any material not assigned to a face will not be added - in addition it requires a unique texture image for each material. The reason for this was to make sure people only export out ASE's without extra & unused materials/textures. Updates will keep rolling out, we have to get Blender deeper into the game development pipeline!

    In a future update i'll make it detect the UCX_Collision mesh name and void the material / texture requirements.
    Makes sense and sounds great.

    Smoothing groups might be a time sink, i've talked with some people about it...maybe there is a workaround. Besides, exporting multiple uv maps correctly is more important!
    Aren't smoothing groups suppose to help determine if the shading will be either smooth or hard for the edges? Agreed that multiple UVs are very important.

    --edit: and yes it needs a *.ase name, if you save your .blend it should have [project_name].ase already filled out.
    This works as you just mentioned. I thought by the wording on your site that if you didn't have the ".ase" part, it would automatically add it. Not a big issue either way.

    Glad I helped out someone,
    Indeed

    Keep in mind that more people will appreciate your work than what is commented. The same is true with with my tutorial sections.

  5. #5
    MSgt. Shooter Person
    Join Date
    Apr 2010
    Posts
    211

    Default

    Very big thank you MCampagnini!

    This has long been sort after in the new 2.5x series.

  6. #6
    Skaarj
    Join Date
    Mar 2011
    Location
    france
    Posts
    29

    Default

    hey, great work !

    Yeah the lack of udk friendly smoothing groups is really a pain in the ass with blender. For now I use fbx exporter tweaked to get smoothing groups from material channels of another object prefixed "SG_". It's not awesome but better than nothing.
    PixoLoco
    "Les chiffres, c'est pas une science exacte figurez-vous!"

  7. #7

    Default

    I do have a plan to fix the smoothing group issues...whether it works or not has yet to be determined. Applying the edge split modifier serves as a work-around, read more about it being used in the original Rich_is_bored script here. From what Kat has told me, Blender applies smoothing groups per vertex and 3DSM applies it per face.

    Thanks for the feedback everyone, still plenty to do.

    MC

  8. #8
    MSgt. Shooter Person
    Join Date
    Jan 2008
    Posts
    255

    Default

    I had the same problem with the 2.56b .ase script in that it forgets the extension on the export file type. That will be a welcomed fix.

    I do hope you can get the smoothing groups issue fixed. I seem to recall that the problem is also in the .fbx export as well. Too bad they don't have more UDK tools do do this in the Add-on section of the program. I would think a stable way to transfer stuff from blender to UDK would be a great addition to blender!

  9. #9
    Skaarj
    Join Date
    Mar 2011
    Location
    france
    Posts
    29

    Default

    Hmm, I just tried again the edge split method, I can't make it work, udk seems to merge vertex in the same smoothing group.

    Here is what I have on a cylinder.
    The left is real smoothing groups like in 3ds max, the right is the edge split method with edge split modifier aplied. I verified that the vertex was really separated.


    Maybe i'm doing something wrong... If anybody manage to have the left cylinder with an edge split, please let me know.
    PixoLoco
    "Les chiffres, c'est pas une science exacte figurez-vous!"

  10. #10

    Default

    ideally (again this is 2nd hand) the edge split should apply smoothing groups to the seam areas.

    getting the multiple uv maps out is a much quicker fix than this problem, so I will be handling that first, and then, i'll dive into blender smoothing groups...

  11. #11
    MSgt. Shooter Person
    Join Date
    Mar 2011
    Posts
    146

    Default

    Why would i use ase exporter over fbx one (when working from blender)? Asking more out of curiosity as I ll probably be creating only placeholders as im more interested in programming.

  12. #12
    MSgt. Shooter Person
    Join Date
    Mar 2011
    Location
    Uruguay (South America)
    Posts
    271

    Default

    This is awsome man! I was waiting patiently for a propper script for this. I really wanted to stop using old 2.49
    Thank you so much. You should enable a "Donate!" section in your site.

  13. #13
    MSgt. Shooter Person
    Join Date
    Mar 2011
    Location
    Uruguay (South America)
    Posts
    271

    Thumbs up

    Quote Originally Posted by rogacz View Post
    Why would i use ase exporter over fbx one (when working from blender)? Asking more out of curiosity as I ll probably be creating only placeholders as im more interested in programming.
    Well simply because FBX don't work that good yet :S

  14. #14

    Default

    Quote Originally Posted by ilguano View Post
    You should enable a "Donate!" section in your site.
    it's there...snug at the bottom of the post

    At the moment Blender has issues exporting from most UDK file formats. The goal is to get Blender in the position where it can be used just as well as any other $$$$ modeling package...starting with the ASE Exporter.

    Latest updates:
    Will not export the material if:
    • The material is not found on any mesh face
    • The texture image slot is not a unique image file

    The reasons for this are to avoid adding materials that are duplicates and/or unused.

    Other updates
    • Added a checkbox option to triangulate the mesh or not
    • Will not export any materials applied to the collision model (must have UCX_ prefix, ill add the other prefixes later)

    Time to work on the multiple uv maps!

  15. #15

    Default

    Quote Originally Posted by rogacz View Post
    Why would i use ase exporter over fbx one (when working from blender)? Asking more out of curiosity as I ll probably be creating only placeholders as im more interested in programming.
    For what it's worth, having MCampagnini updating the script also helps out the UT 3 (and possibly other communities) that can only use .ase as a proper import option.

    Quote Originally Posted by MCampagnini View Post
    i
    Other updates
    • Added a checkbox option to triangulate the mesh or not
    • Will not export any materials applied to the collision model (must have UCX_ prefix, ill add the other prefixes later)

    Nice progress.

  16. #16
    MSgt. Shooter Person
    Join Date
    Dec 2009
    Posts
    292

    Default

    Quote Originally Posted by MCampagnini View Post
    it's there...snug at the bottom of the post

    At the moment Blender has issues exporting from most UDK file formats. The goal is to get Blender in the position where it can be used just as well as any other $$$$ modeling package...starting with the ASE Exporter.

    Latest updates:
    Will not export the material if:
    • The material is not found on any mesh face
    • The texture image slot is not a unique image file

    The reasons for this are to avoid adding materials that are duplicates and/or unused.

    Other updates
    • Added a checkbox option to triangulate the mesh or not
    • Will not export any materials applied to the collision model (must have UCX_ prefix, ill add the other prefixes later)

    Time to work on the multiple uv maps!
    Nice progress!
    I have a question, though: Does smooth-grouping by Vert Splitting work with the exported .ase?

    //e: I was too stupid to read the posts above; it's nice that someone's planning to integrate smoothgroups and multi-UVs!
    Last edited by Analdin; 04-19-2011 at 02:48 PM.

  17. #17

    Default

    Quote Originally Posted by MCampagnini View Post

    • Will not export any materials applied to the collision model (must have UCX_ prefix, ill add the other prefixes later)

    I updated my site with version 1.0.3. Regarding the above change, you still need to assign a material/texture/image and UV map the collision object for the exporter to work.

    I presumed that if you had the UCX_ prefix, the exporter wouldn't require that object to have a material or UV map since it will be invisible in the game.

    I just wanted to clear this up for others.

    p.s. Out of curiosity, is there a way to permanently change the scale value in Blender to 1? I build all my meshes at the same size as they would be in UT 3.

  18. #18

    Default

    Quote Originally Posted by Odedge View Post
    [/LIST]
    I presumed that if you had the UCX_ prefix, the exporter wouldn't require that object to have a material or UV map since it will be invisible in the game.
    That is the plan, I only made it so it doesn't export the materials / textures - a later release will complete this and allow it to pass other checks. Working on the uv mapping issues now, I am hoping to wrap it up today or tomorrow.

    Not sure if this will help, but in Blender I use a scale of 1.00, with 16 lines, and 10 subdivisions (press n in viewport and go to display). The exporter scales it up x16 for UDK. See if that works for you.

  19. #19

    Default

    Quote Originally Posted by MCampagnini View Post
    Not sure if this will help, but in Blender I use a scale of 1.00, with 16 lines, and 10 subdivisions (press n in viewport and go to display). The exporter scales it up x16 for UDK. See if that works for you.
    I tried it, but the issue for me is that it's too hard to tell when you are on the "1" grid unit and you can go lower.

    I set my scale to 64 and subdivisions to 8. The scale of 64 won't let you see lower than a 1x1 grid, which makes more sense to me when making something to use in the Unreal editor.

  20. #20

    Default

    just to give everyone an update on where i'm at -

    im about 95% done with the code to allow for multiple uv's, just one line of code left that i have to figure out to tie it all together (thanks to the Blender Foundation jokesters who think API docs should consist of only function names, not descriptions and examples )

    getting there, i'll do another post and video on my site when i upload it.

  21. #21

    Default

    Quote Originally Posted by MCampagnini View Post
    getting there, i'll do another post and video on my site when i upload it.
    Looking forward to it.

    I spent some time yesterday practicing with the multiple materials and how to properly see them in Blender. At first, only 1 texture was displaying on the entire model.

  22. #22

    Default

    remember that with the updates, the video is no longer up to date. multiple materials will not export if they are 1) not assigned and 2) do not have a unique image in the image texture slot.

    #2 is probably what got you. in the video I used "untitled" for both materials, now you cant do that, use "untitled.001" or something.

    3) theres a bug, but lets hope not...

  23. #23

    Big Grin

    ASE Exporter vMC 1.04

    Main Features:
    • Multiple UVs Support
    • Multiple Material
    • Quality of Life Updates

    Next Up:
    • Smoothing Groups!

    1.04 introduces multiple uv exporting, we've got two of the three milestones down (Multiple materials and multiple uvs), leaving only smoothing groups left! Time to celebrate...who's buying the first round? /cheers

    The video and information on the site will be updated for the current version tomorrow...too late to do it now...

    To odedge: The collision models still need a material / uvs, i'll go back to it later.

  24. #24

    Default

    Quote Originally Posted by MCampagnini View Post
    ASE Exporter vMC 1.04

    Main Features:
    • Multiple UVs Support

    Nice. My site has been updated as well.
    Next Up:
    • Smoothing Groups!

    Good to hear. Out of curiosty, do smoothing groups have the same general effect has either "smooth" or "flat" shading in Blender?

    Time to celebrate...who's buying the first round? /cheers
    Next person to post is buying.

  25. #25
    MSgt. Shooter Person
    Join Date
    Jan 2011
    Posts
    187

    Default

    good work.

  26. #26
    MSgt. Shooter Person
    Join Date
    Dec 2009
    Posts
    292

    Default

    Quote Originally Posted by MCampagnini View Post
    ASE Exporter vMC 1.04

    Main Features:
    • Multiple UVs Support
    • Multiple Material
    • Quality of Life Updates

    Next Up:
    • Smoothing Groups!

    1.04 introduces multiple uv exporting, we've got two of the three milestones down (Multiple materials and multiple uvs), leaving only smoothing groups left! Time to celebrate...who's buying the first round? /cheers

    The video and information on the site will be updated for the current version tomorrow...too late to do it now...

    To odedge: The collision models still need a material / uvs, i'll go back to it later.
    Awesome sauce!
    Now only the smoothgroups remain, great progress!

  27. #27

    Default

    i might be finished with implementing the smoothing groups as early as tomorrow. it will, however, require that the mesh be triangulated.

  28. #28
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Location
    Vancouver, Canada
    Posts
    84

    Default

    Great work, it's been nice how easy this is to use. Smoothing groups would make it even better once you have those.

    For scaling, myself I prefer to work in cm so for my needs it's actually a whopping scale of 50 (2cm = 1 UDK unit and I guess it assumes metric scale = 1 meter). Any way we can easily set the scale default for the exporter?

  29. #29

    Default

    yeah the smoothing groups are getting complicated - i implemented a slider so you can set which degree to break up your smoothing groups into. it's working but needs some refinement. it won't be done today like i had hoped, maybe sunday.

    your gonna have to open the code to set it to a default. get this line near the bottom and change both default values to what you want.

    ASE_SCALE = FloatProperty(name="Scale", description="Object scaling factor (default: 16)", min=0.01, max=1000.0, soft_min=0.01, soft_max=1000.0, default=16.0)
    Last edited by MCampagnini; 04-22-2011 at 09:50 PM.

  30. #30
    MSgt. Shooter Person
    Join Date
    Apr 2011
    Location
    Vancouver, Canada
    Posts
    84

    Default

    Quote Originally Posted by MCampagnini View Post
    yeah the smoothing groups are getting complicated - i implemented a slider so you can set which degree to break up your smoothing groups into. it's working but needs some refinement. it won't be done today like i had hoped, maybe sunday.

    your gonna have to open the code to set it to a default. get this line near the bottom and change both default values to what you want.

    ASE_SCALE = FloatProperty(name="Scale", description="Object scaling factor (default: 16)", min=0.01, max=1000.0, soft_min=0.01, soft_max=1000.0, default=16.0)
    Thanks.

    I wonder, is there any way to put smoothing information into the .ase based on any Blender modifiers that are not applied yet? Or does Blender auto-apply before you get the data to the exporter?

    From what I gather, the problem is that UDK on import will clean up the edges if they aren't specifically in smoothing groups in the format it expects from Max, etc.?

    Also, on katsbits there's a Blender 2.49 .ase exporter that supposedly forces Max-style smoothing groups. I don't know if that's a helpful example but here's the link: http://www.katsbits.com/tools/#ase

  31. #31

    Default

    Trying to look through code written for blender 2.4x would only hurt my head, it's very different now. Blender saves out smoothing "groups" per vertex, 3dsm does it per face. I don't know if it's possible to pull out the smoothing group of each vertex through the api, docs are pretty scattered at the moment.

    What i'm doing to calculate out the smoothing group (layman's) is finding the poly normal between two faces, find the angle difference between the normals and checking if it is within the set range, if it isn't it belongs in a separate smoothing group. Pretty simple concept.

    I don't know what UDK does, but its not as pretty as if you exported from max. But i'm going to fix that.

  32. #32
    Redeemer
    Join Date
    Mar 2009
    Posts
    1,051

    Default

    Bless you for taking this on, Blender has needed this badly. All the kudos in the world to you

  33. #33
    MSgt. Shooter Person
    Join Date
    Dec 2009
    Posts
    292

    Default

    Quote Originally Posted by MCampagnini View Post
    Trying to look through code written for blender 2.4x would only hurt my head, it's very different now. Blender saves out smoothing "groups" per vertex, 3dsm does it per face. I don't know if it's possible to pull out the smoothing group of each vertex through the api, docs are pretty scattered at the moment.

    What i'm doing to calculate out the smoothing group (layman's) is finding the poly normal between two faces, find the angle difference between the normals and checking if it is within the set range, if it isn't it belongs in a separate smoothing group. Pretty simple concept.

    I don't know what UDK does, but its not as pretty as if you exported from max. But i'm going to fix that.
    Just an idea, would it work to put all connected verts into one smoothing group? That way, we'd have good vert split smoothgroups.
    But as I have no idea of what the Blender API is capable of, I have no clue if that would work...

  34. #34
    Skaarj
    Join Date
    Mar 2011
    Location
    france
    Posts
    29

    Default

    I think it won't work (i tried something similar for fbx) : The biggest problem is that smoothing groups are coded on 32bits. You "only" have 32 smoothing groups available (because each bit represent one smoothing group).

    Lets say you have an object with 6 cube in it, 6*6 = 36 smoothing group.
    If you place smoothing groups yourself on those 3 cubes you only need 3.
    PixoLoco
    "Les chiffres, c'est pas une science exacte figurez-vous!"

  35. #35
    MSgt. Shooter Person
    Join Date
    Dec 2009
    Posts
    292

    Default

    True, it'd be kind of a rough solution...

  36. #36

    Default

    I don't think there would be an issue having duplicate smoothing groups in isolated areas (see picture). This would let us get more bang for the buck.



    And here is what would happen if you have two smoothing groups on the same plane.


  37. #37

    Default

    Quote Originally Posted by MCampagnini View Post
    your gonna have to open the code to set it to a default. get this line near the bottom and change both default values to what you want.

    ASE_SCALE = FloatProperty(name="Scale", description="Object scaling factor (default: 16)", min=0.01, max=1000.0, soft_min=0.01, soft_max=1000.0, default=16.0)
    I opened the script in notepad. Can I just save the file after making the changes or does it have to be recompiled? I really like the idea of changing the default value.

  38. #38

    Default

    Save the file, do the same steps you did to install the script.

    Import it, then uncheck the enable icon next to the script, then check it again and you'll be good to go.

  39. #39
    Skaarj
    Join Date
    Mar 2011
    Location
    france
    Posts
    29

    Default

    MCampagnini, if you manage to find isolated area and set already used smoothing group that'd great. I didn't have enough knowledge to find a good solution to that problem when i was tweaking the fbx exporter. I hope you'll find a way. If you do i'll buy you a drink. But as you're not here, i'll drink it for you
    PixoLoco
    "Les chiffres, c'est pas une science exacte figurez-vous!"

  40. #40
    Iron Guard
    Join Date
    Jun 2009
    Location
    Where the ganja is plentiful
    Posts
    717
    Gamer IDs

    Gamertag: PSN: ShurikenUK

    Default

    Im having weird problems when exporting models from Blender to UDK, and Im wondering if using this plugin would fix them (dont want to bother if its not going to fix the problem):-

    -Models when brought into UDK are a different shape (eg: a narrow cone, when in UDK, becomes a WIDE cone)

    -Models brought into UDK become partially destroyed (Large percentage of faces are missing, or invisible)

    thanks
    There is no religion except that of Music. There is no god, except that of your own will to create music.
    -Ancient Texts of Truth


 
Page 1 of 11 123 ... 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
  •  
Copyright ©2009-2011 Epic Games, Inc. All Rights Reserved.
Digital Point modules: Sphinx-based search vBulletin skin by CompletevB.com.