Shop OBEX P1 Docs P2 Docs Learn Events
Reading 3D files with the Propeller? — Parallax Forums

Reading 3D files with the Propeller?

MicrocontrolledMicrocontrolled Posts: 2,461
edited 2010-08-09 14:44 in Propeller 1
What is the composition of common 3D filetypes? The COLLADA filetype, specifically.
I've seen 3D files decoded with microcontrollers before, so why not the Propeller?

Also, is there enough on-board RAM space for decompression?

Thanks,
Micro

Comments

  • JonnyMacJonnyMac Posts: 9,208
    edited 2010-08-09 10:29
    Two milliseconds of research would net you the information you're asking for, that really has nothing (specifically) to do with the Propeller.

    -- http://www.khronos.org/collada/
  • trodosstrodoss Posts: 577
    edited 2010-08-09 10:35
    @Microcontrolled:
    You might want to take a look at the thread (on the old forum) http://forums.parallaxinc.com/forums/default.aspx?f=25&m=358882

    Phil Pilgrim had a wireframe 3D example.

    Also Baggers has done some work with 3D (I think it was PropGFX-based), so you might search for that in the Hydra forum.

    None of these are COLLADA format, but might give you some ideas of how to get it done.

    --trodoss
  • potatoheadpotatohead Posts: 10,261
    edited 2010-08-09 11:11
    Seems to me, about the only 3D files that would be practical on the Propeller, are DXF, and STL, maybe OBJ.

    All three of those can do wireframe. STL is just a triangle file, and OBJ can contain a lot of things, including color definitions.

    A prop trudging through those could render an image to the screen, or to another buffer file, to be displayed after processing the file has completed.

    There isn't enough RAM to do much else.

    Baggers has polys in PropGFX... Those are real time, but I don't know their characteristics yet.

    Probably something like this would have to be done in stages.

    Load COGs with simple text driver and file access code.

    Read through the source file, producing output files.

    When done, unload a lot of stuff, load in video display driver, and some simple I/O, maybe keyboard mouse.

    Read output files and render to screen.
  • BaggersBaggers Posts: 3,019
    edited 2010-08-09 12:37
    The PropGFX Virtua Fighter style character demo I did had 400 polys ( or 398 something like that ) and using a single cog could render 3.5 at full screen 128x96 8bit mode, or 256x192 1/2/4 bit mode, at 60 fps, easily, and the PropGFX had the option to use 4 cogs for 3D, so this would be ~4* faster, and so that's 1400*4cogs 5600 polys per 60fps, 336,000 polys per second, which isn't too bad for a little micro controller :D

    Edit: I used a proprietary file format, that I made for exporting models from Lightwave.
  • mctriviamctrivia Posts: 3,772
    edited 2010-08-09 13:43
    STL I find is the most common. Check out http://thingiverse.com there are all kinds of cool designs out there(some of which I designed: http://www.thingiverse.com/mctrivia )
  • potatoheadpotatohead Posts: 10,261
    edited 2010-08-09 14:44
    Looks like my screenie is gone :( -->I wrote a STL file viewer in C for IRIX, Windows, Linux.

    http://viewstl.sourceforge.net/

    The Linux version is the most current. Will do million polys, no sweat!

    The format is very simple. Maybe that bit of code helps to understand something about how this kind of thing can go.
Sign In or Register to comment.