Tuesday, January 20, 2009

Bicubic patch meshes

Some progress with RibRender.. I've got the bicubic patch meshes somewhat working.


See the airplane. Including the elephant image too, though that's using just bicubic patches (not meshes).. but it's cool anyway 8) And it renders properly because I fixed some transformation state machine bug that I had lingering around.
I also changed the rendering to retained mode: primitives are collected, state machine snapshots are stamped onto primitives, and everything is rendered when the whole scene description is finished (at WorldEnd time).
A graphic state is only saved when changed and being referenced by one or more primitives (state change detection is based on a simple counter, a simplistic approach, but better than nothing for now).

Xcode has been a mixed experience so far. I like the editor predictive feature (I enabled it all the way to suggest me what I may be want to write right away).
The IDE layout is a bit painful to use: windows opened all over the places, I really miss being able to switch between recent source files with CTRL+TAB.
Refactoring for C++ isn't possible at all (Visual Studio can't do this neither, but Visual Assist X can, and it's a great time saver to cleanup/refactor code !).

Worst of all Xcode debugger seems rather ancient (based on GDB, which should be good, but the interface surely shows little).
I had a very hard time trying to debug STL vectors.. there is some option out there to improve vectors debugging (-D_GLIBCXX_DEBUG), but that didn't really work in my case.
I generally can't see the vector's content, sometimes I can see the start pointer and end pointer.. but I can't find a way to get the debugger to show a list of items from that pointer (CodeWarrior on PS2 had this "View As Array of.." option, while with Visual Studio one can use something like pItems,16  to see an array of 16 elements out of a pointer).

Now I have some crashes, but, unlike with Visual Studio, Xcode debugger doesn't throw me in the hot spot... in fact I just came back from a machine reboot: the application crash while running in the debugger left me only with a moving mouse pointer, while the system UI was deadlocked.

Ummmmmmm... I'm clearly a newbie with Xcode, but I have the feeling that the debugger truly isn't at the level of the Visual Studio one... and in the long run that will become a serious issue, a reason alone to start aiming at multi-platform and develop mostly under Windows (possibly emulated under OS X 8).

zzzzzzzzzzzzzzz

9 comments:

  1. Cool cool, progress!!!!

    Visual Studio is definitely the top IDE. I've been trying to use something called Eclipse for Cell development and gave up after a while. I think part of the issue is that I am running it over VNC client connected to a Ps3 linux installation. Sometimes the editor gets slow to the point of being unusable.

    I had the idea of making a network share on the Ps3 linux machine and do all my source editing in visual studio, but I cant seem to be able to connect Vista or XP to the linux share. I spent days trying various suggestions that I got from the internet, but still no luck =(

    ReplyDelete
  2. Hi Davide,
    Very interesting progress about RibRender :)

    Anaway, this post is not very related to the original topic, but I didn't find a proper way to write to you.
    I've been reading your blog for a while, it is interesting, I like 3d real-time programming.
    I know you (your name) for the RTMZ, the old but very well done dos 3d engine :). I got it lots of years ago from public collections of 3d engines, and it suprised me for the quality and speed, related to other engines. At the time I was a beginner, looking for material to learn from. Today I'm not a professional either, as you are, I work almost with boring databases and other enterprise applications, but I learnt something more about 3d :)
    So, I'd like to keep in contact with you, but I wouldn't write my email in a public post.
    My name is Claudio, nick Cody, a 30 year old boy from Firenze :). You should see my google account, so you should be able to anserw to me.
    See you!

    ReplyDelete
  3. Paul,
    A stream processor running a an IDE written in Java (I believe ?) over a VNC connection.. I can see an usability problem with that..

    About Samba over Linux.. good luck ;)


    Claudio,
    Wow.. it's always nice to hear about someone remembering about RTMZ 8)
    The link to your Google profile doesn't give me any hints on your email address. If you want to contact me feel free to write at dpasca at gmail.com 8)

    ReplyDelete
  4. I remember RTMZ!!!!

    Mr, 'I write everything in C with no asm'.

    ReplyDelete
  5. Hey Kaz,

    I think there's an option in XCode to keep all the windows in the IDE ... I can't remember where it is though (one of the pains about XCode's IDE).

    ReplyDelete
  6. Paul,

    Let the compilers do their job 8) ...still, stuff simple enough to write directly in assembly. I miss that relative simplicity !

    Ragin,
    From the general settings there is the "All-in-one" option.
    It's a bit weird how it works. Doesn't seem too useful without being able to rotate files with CTRL+TAB.
    Also the Find In Files gets embedded at the top of the window.. still, I'll try and see how it goes.
    I just noticed that by pressing CTRL+TAB 2 times from the editor I can do a source file name search.. useful !

    ReplyDelete
  7. Kaz,

    There is still some of that 'simple stuff' left, although now we are encouraged to use intrinsics for cross platform compatibility.

    Some things the compiler still cant do efficiently. For example moving memory using 16 byte registers to and from unaligned addresses.

    ReplyDelete
  8. Dr. Positive Paul (where did that web site end ?!),

    I remember on the PS2 using intrinsics was a cool thing when I wanted to keep vertices stored in fixed point but also needed to unpack them for skinning on the CPU. I can see that happening again and again.. however, right now I'm busier streaming, splitting work into threads and trying to cope with monster-size textures, geometry, shaders.
    I could use some loop-optimizing work for a change 8) ..but I'm limited by APIs ! ..facking APIs !!

    ReplyDelete