Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Everything posted by Porthos

  1. An Open Source 3D Model Viewer I just released: open3mod. Supports 30+ file formats, including Collada, OBJ, STL, FBX, BLEND, 3DS, X, MD5 ... and does export to STL, DAE, OBJ and some others, which may make it useful if you want to get some ancient 3D model into e.g. STL for your printing. It is backed by Open Asset Import Library (also known as assimp), which I've been co-working on for a couple of years.   Supports split view, multiple open tabs. animation playback and deep insight into the scene hierarchy. Also, you can fix missing textures on the fly.   Full list of supported file formats   Download at open3mod.com   [attachment=22311:shot1.png] [attachment=22312:shot2.png] I've been working on this on and off for about two years. It has never been a priority, but it continuously distracted me from other stuff, so I figured it was time for a first release. Feel free to share! Any feedback welcome.?
  2. Porthos

    Assimp strange issue.

    Would be great to see the relevant pieces of your code. Bye, Alex
  3. Porthos

    Custom Model Format

    Consider using an existing file format, such as Collada, Obj, 3DS whatever suits your needs. Also, nothing speaks against the .X format if you have a working exporter and importer for it - after all, it's just your data pipeline. As long as it works, no one cares how old your file formats are. I recommend using a library such as http://assimp.sourceforge.net to do the model loading for you.
  4. Porthos

    MD2 Loader

    Assimp reads MD2 as well (amongst many other formats), but it does not currently support vertex animations. If you don't need those, it might be useful for you.
  5. Try to flip the y coordinate of the UVs (y=1.f-y). That's a typical issue with DirectX, which chooses the opposite UV convention than Assimp. Note that you can configure Assimp to do this for you early in its pipeline by specifying the aiProcess_FlipUVs flag in addition to your existing setup. Bye, Alex
  6. Porthos


    >> 1. How does it work? How do you implement a script? By compiling it into bytecode, then execute it in a virtual machine within the process. That's done by the runtime library of the scripting language of your choice, you don't need to care of it. Simply use the API the language provides. >> 1. What type of occasions demand scripting? When should you use it? For everything that is no performance-critical, because scripting languages typically provide a much faster workflow and are less error prone.
  7. Porthos

    Collada Hell

    I'm going to talk with the author of Assimp.net. However, this subproject is not required for running the Assimp library from C/C++, it's totally independent. >> I have a question before updating to the latest version of Assimp: are there any world shocking changes made to it? I mean, will I be able to use Assimp the way I'm using it now or has the base functionality and/or structure changed? No breaking API changes, everything should just work fine. Most of the changes since the last prebuilt package went into the Collada loader, so you might profit a lot from updating.
  8. Porthos

    Collada Hell

    First of all, thanks for all recommendations of Assimp :-) Unfortunately, wiegje85 is right about at least one fact: for a few days, Assimp's SVN head was broken, but it should be fixed now ... right now, I did a clean checkout and it compiled perfectly for me, both with vc8 and vc9. I didn't check with gcc yet, however. No missing files at least - maybe you're missing boost? - this can be avoided by using the -noboost project configs. It would be great if you could retry compiling latest SVN-Assimp. Please contact me if it still doesn't work! And my final two cents regarding Collada: it would be a great format, but it's over-engineered by at least 3 magnitudes. I'm not sure whether the latest spec defines extensions to support Klingonian coordinate systems, but I wouldn't be surprised if they existed :-) -- Alex
  9. Porthos

    [SlimDX] Load Model

    Yes, a C# port is pending, but they guy working on it didn't do anything in the past few months. I don't think there's much more than empty units with some (outdated) data structures. So far, you would probably need to do the API port yourself if you wanted to use it :-) >> think I would use this library, but how can I access it's methods/classes You'd need the Assimp data structures redeclared in C#, and a binding to copy the native data structure to the managed one. I haven't much experience with .NET, so I can't say how difficult that would be. Definitely less difficult than writing a few loaders on your own :-) Bye, Alex
  10. Porthos

    [SlimDX] Load Model

    I don't know much of SlimDX, but you could try to integrate the Assimp library. It supports loading of .X files, along with several other formats (around 25). Beware, I'm one of its developers so I might be biased here :-) And it's native C++, a C# port is now pending for a long time. >> Later I also want to use skinning and animations, is this possible with .x? Yes, .X supports skinned meshes. Another possibility is the Doom3 MD5 format. >> And do I have to write a loader for binary and text based .x files? There's even a third kind of X files, ZIP compressed. >> Are there different "versions" of the .x file format? X is not really well-defined and (afaik) not versioned, writing your own loader is generally a bad idea. You'll need to workaround several faulty exporters, ... Bye, Alex
  11. Hi, Assimp has some nice models in its repository (here). x/dwarf.x, x/Wuson.x and especially md5/bob.md5 should be suitable for your purposes. Be sure to use the latest Assimp SVN version for best .. ehm ... loading experience :-) If that's not enough for you, I can provide some animated MD5 and X files either collected from various sources on the internet or made by friends, all tested with Assimp but naturally not intended for public use. Alex
  12. Porthos

    ASSIMP with SDL and OpenGL

    Hi, Assimp's output data is already suitable for rendering with OpenGL. The coordinate system is right-handed and the face order *should* be counter-clockwise. The most important thing: understand the output data structure of the library before you start coding. There are no tutorials yet because Assimp is still in beta stadium (I assume you're using beta 1). However, as Thomas said already, the documentation should tell you everything you need to know. First of all you need to get Assimp running. Then you should find a configuration (postprocessing steps, config options) that fits best to your needs (performance vs. quality tradeoff). Then I'd suggest you to start implementing code to render Assimp meshes (aiMesh). After that you should have no problems implementing and understanding the rest of Assimp's data structure. --- Alex PS: If you want more features and better format support but a possibly less stable version take the current SVN version of Assimp. Any feedback is highly appreciated. [Edited by - Porthos on October 19, 2008 5:09:58 PM]
  13. Porthos

    Load PNG

    Try LodePNG. It is extremely easy to use, although not as fast as LibPNG. If you want to support many image formats at once, try DevIL. -- Alex
  14. Porthos

    best 3d fil format?

    First of all, please stop to post the same question in two subforums as you did now and as you've done for your question regarding 3ds. (Skeletal) animation: md5, collada, x Static: collada, 3ds, obj, x, ...
  15. Porthos

    .3ds loading

    Take a look at lib3ds or ask google with keywords like "3ds loader c++" or "3ds file format". You will find much! Using google is often a good way to solve problems ... >> But i also want know if its probable to get texture >> coordinates from .3ds file ? 3ds supports one texture coordinate set, yes. --- Alex
  16. And how do you want to find the exact location where the camera data lies? ToohrVyk's approach (controlling input) is much easier to implement, I assume. The next thing is, some virus scanners don't like applications which call WriteProcessMemory() since the function can be used to inject DLLs into processes. And I'm not sure whether they changed the behaviour of the function in Windows Vista. At least an old application I wrote some years before has problems calling WriteProcessMemory() under Vista. --- Alex
  17. Porthos

    Extra polygon

    If no one knows a better solution, solution 3 should be the fastest. --- Alex
  18. IrrXML might be worth a try, too. It is extremely lightweight and easy to use. Website
  19. Porthos

    is this right?

    const char* c_str ( ) const; c_str() returns a pointer to a constant buffer, so the code you've posted is not legal. Try this: const char* charStr = str.c_str(); or (evil but possible) char* charStr = const_cast<char*>(str.c_str()); --- Alex
  20. Porthos

    blender and 3ds

    Well, the blender 3ds importer is buggy and works not often correctly. In fact, it seems at least to ignore the pivot points of the model (and other parts of the transformation are false, too). Try X-Files. There are good exporters for 3ds max and Blender should be able to read them. OBJ is worth a try, too. --- ALex
  21. Porthos

    a beginner ideia of optimization

    Yes, sorting by (texture-, material-, shader-, ...)IDs is a quite good way to optimize the rendering process for opaque meshes. However, for transparent objects you'll need to sort back-to-front.
  22. "MyClass(this)" should be OK, I think. The this pointer is always of type "Type* const", but the compiler should cast the const implicitly away (as the pointer is passed by value). As alvaro said, the type of "new MyClass(this)" is MyClass*, not MyClass. Are you sure the compiler isn't complaining about that?
  23. Porthos

    2d Image distortion effect

    Most games use (afaik) a distortion map for their distortion/perturbation effects (such as heat distortion). It's simply a map containing an offset vector for each pixel - typically encoded in the red and green color channels. The distortion is done in a postprocess pixel shader. Each pixel is shifted by the corresponding offset - of course you can do it in software, too. The main problem is how to get a realistic water drop. It think a water drop is a flat sphere (and you're looking down at it). If a ray enters the drop, refraction occurs, depending on the refraction index of water (constant) and the input angle. You could follow this ray until it intersects the base plane. Then cou can simply take this as the offset vector for the intersection point. Don't know whether this works. I hope it does. Well, it is at least a good approach to start with. --- Alex
  24. Porthos

    Looking for library

    Take a look at the large Open Source 3D Engines, such as OGRE, CrystalSpace and Irrlicht. http://www.ogre3d.org/ http://irrlicht.sourceforge.net/ None of them is a CryEngine 2, but they are free and portable, and yes, you may compile them from the command line with MinGW. --- Alex
  25. Porthos

    MD5 Use

    MD5 files have been intended to store geometry for skeletal animations. Thus the file formats defines bones and vertex weights. However, nothing speaks against using the file format for fully-static meshes! --- Alex
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!