Page 11 of 21 FirstFirst ... 678910111213141516 ... LastLast
Results 151 to 165 of 307

Thread: Coder's Hang-out

  1. #151
    crusher's Avatar
    crusher is offline ↑ ↑ ↓ ↓ ← → ← → B A START
    Join Date
    Jun 2002
    Posts
    15,697
    Thanks
    3
    Thanked 22 Times in 17 Posts
    EP Points
    35

    Default

    I've found another method that I'm gonna try to get working. Because the one I posted above will only work if the leg consist of two parts. I might want to use more.

    Check this out: http://freespace.virgin.net/hugo.elias/models/m_ik.htm

    Yet again, I understand the concept but I don't remember shit when it comes to math... How do I calculate the force vector? And how do I calculate the dot product?

  2. #152
    Join Date
    Feb 2005
    Location
    Limbo
    Posts
    3,706
    Thanks
    0
    Thanked 2 Times in 2 Posts
    EP Points
    10

    Default

    You've got two vectors, with n coordinates (a1, a2, a3 ... an) and (b1, b2, b3 ... bn). Their dot product is a1*b1+a2*b2+a3*b3+...+an*bn.
    Dot product of two vectors, as you could see, is the orthogonal projection of one vector on the other, if one of them has a length of one. If not, it's that much longer. Therefore that R right angle vector in the tutorial should be one unit long, so that (R.F) would exactly be the amount of force that rotates the bone.
    You don't calculate force, here, unless you want stuff to move on their own, due to gravity, or something, rather just apply some kind of force. Most appropriate would be to make the force proportional to the distance, (or probably square root of the distance)
    Good thing that I do know a little bit about physical simulations, so adding forces/restraints in to the equation makes it a lot simpler for me.

  3. #153
    crusher's Avatar
    crusher is offline ↑ ↑ ↓ ↓ ← → ← → B A START
    Join Date
    Jun 2002
    Posts
    15,697
    Thanks
    3
    Thanked 22 Times in 17 Posts
    EP Points
    35

    Default

    I can only come up with one reply: I'm so confused.

  4. #154
    Join Date
    Feb 2005
    Location
    Limbo
    Posts
    3,706
    Thanks
    0
    Thanked 2 Times in 2 Posts
    EP Points
    10

    Default

    Try doing the spider example first, then some basic physics thingy (like, a bouncing ball or something similar), to get an idea on how you'd code something like that, and then you could go over to that multiple joint example.

  5. #155
    Join Date
    Aug 2004
    Posts
    6,802
    Thanks
    30
    Thanked 98 Times in 49 Posts
    EP Points
    205

    Default

    I got the 1st Q of my report portfolio done . The loop was a bit difficult to figure out seeing as values had been changed, so I just did it so that it added or subtracted away from values to bring it back to normal (I presume thats the least hassle unless there is a better way to reset values )

  6. #156
    Join Date
    Aug 2004
    Posts
    6,802
    Thanks
    30
    Thanked 98 Times in 49 Posts
    EP Points
    205

    Default

    Just a quick Q which may mean me actually going home to do this assignment Q, is there much difference between a Win32 program in Visual C++ 6.0 and Visual Studio 6.0 net?

  7. #157
    Join Date
    Feb 2005
    Location
    Limbo
    Posts
    3,706
    Thanks
    0
    Thanked 2 Times in 2 Posts
    EP Points
    10

    Default

    .net uses the dreaded .net thingy, which is AFAIK similar to the Java runtime environment. Kind of like M$'s own Java. Hooray for capitalism.
    Anyhow, there should be no compatibility issues, or at least not that big problems that need more than a few lines of code change.

  8. #158
    Join Date
    Aug 2004
    Posts
    6,802
    Thanks
    30
    Thanked 98 Times in 49 Posts
    EP Points
    205

    Default

    Quote Originally Posted by Dak'kon
    .net uses the dreaded .net thingy, which is AFAIK similar to the Java runtime environment. Kind of like M$'s own Java. Hooray for capitalism.
    Anyhow, there should be no compatibility issues, or at least not that big problems that need more than a few lines of code change.
    ahh, its just I'm currently going through question 3 which I don't think will be as hard when I get round to it. its a Gui with my name and student number on it. and I have to allow the option to change the font on it. which in theory doesn't sound as hard as the pointer and array crap I've been doing on question 2 and the morsecode assignment.

  9. #159
    Join Date
    Aug 2004
    Posts
    6,802
    Thanks
    30
    Thanked 98 Times in 49 Posts
    EP Points
    205

    Default

    ok, this is taking the piss, I have no idea how this is supposed to work

    Download Links:
    Links are hidden from guests. Please register to be able to view these links. It won't compile, I believe this to be a 6.0 issue rather then a compilation error.

  10. #160
    Join Date
    Feb 2005
    Location
    Limbo
    Posts
    3,706
    Thanks
    0
    Thanked 2 Times in 2 Posts
    EP Points
    10

    Default

    Quote Originally Posted by TheotheImpaler
    ok, this is taking the piss, I have no idea how this is supposed to work

    Download Links:
    Links are hidden from guests. Please register to be able to view these links. It won't compile, I believe this to be a 6.0 issue rather then a compilation error.
    Not really. I know nearly nothing about the Windows API, but I'm dead sure you can't declare functions inside other functions. Anyhow, it still wouldn't compile, due to different function declarations. If the above works in .net, then it's because it's .net-specific code. Lack of portability sucks, obviously.

  11. #161
    Join Date
    Aug 2004
    Posts
    6,802
    Thanks
    30
    Thanked 98 Times in 49 Posts
    EP Points
    205

    Default

    Quote Originally Posted by Dak'kon
    Not really. I know nearly nothing about the Windows API, but I'm dead sure you can't declare functions inside other functions. Anyhow, it still wouldn't compile, due to different function declarations. If the above works in .net, then it's because it's .net-specific code. Lack of portability sucks, obviously.
    lol, I reliased that mistake and changed it so that the function was outside it, still in 6.0 and net it won't compile It's becoming more bother then its worth . I still have made no progress on teh GUI program, I think I might just try and put together a fancy GUI as a last resort

  12. #162
    Join Date
    Feb 2005
    Location
    Limbo
    Posts
    3,706
    Thanks
    0
    Thanked 2 Times in 2 Posts
    EP Points
    10

    Default

    http://nehe.gamedev.net/data/lessons....asp?lesson=01
    Dunno how much this helps, maybe you could use some parts of it, sans OpenGL. There are probably better tutorials for Win32, but at least it's well commented. A quick search turned up this:
    http://www.winprog.org/tutorial/
    It looks simple enough. And compiles, at least, so I'd consider it a good start.

  13. #163
    Join Date
    Aug 2004
    Posts
    6,802
    Thanks
    30
    Thanked 98 Times in 49 Posts
    EP Points
    205

    Default

    Quote Originally Posted by Dak'kon
    http://nehe.gamedev.net/data/lessons....asp?lesson=01
    Dunno how much this helps, maybe you could use some parts of it, sans OpenGL. There are probably better tutorials for Win32, but at least it's well commented. A quick search turned up this:
    http://www.winprog.org/tutorial/
    It looks simple enough. And compiles, at least, so I'd consider it a good start.
    hmm, thanks, all I really need is something that will display text/morsecode. I'll try and take another shot at it today as well as some other stuff.

  14. #164
    crusher's Avatar
    crusher is offline ↑ ↑ ↓ ↓ ← → ← → B A START
    Join Date
    Jun 2002
    Posts
    15,697
    Thanks
    3
    Thanked 22 Times in 17 Posts
    EP Points
    35

    Default

    Ok, I got my IK arm working now. Looks great. However, I got a slight problem. I'm currently porting the code to another language... but that language doesn't have an atan2 function and I have no idea how atan2 works. Can't find any info on it anywhere... Anyone willing to help me?

  15. #165
    Join Date
    Feb 2005
    Location
    Limbo
    Posts
    3,706
    Thanks
    0
    Thanked 2 Times in 2 Posts
    EP Points
    10

    Default

    What's that? Arcus tangent? Or, what's the 2 there? Anyhow, you only need arcus cosine for calculating the angles. That'd obviously mean that you have to write that part on your own. Which, I'm guessing, you're reluctant to, you math-hating person, you.
    Anyhow, just tell me what you need that math function to do, I'll look it up. It'd be handy to note the language, too.

Similar Threads

  1. Visit The Hang Out!
    By Georgyw5k in forum Free 4 All
    Replies: 5
    Last Post: 28th-November-2003, 05:18
  2. Do You Hang Up On Advertisement Callers?
    By ((KvN)) in forum Free 4 All
    Replies: 52
    Last Post: 21st-July-2003, 11:16

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About Us

We are the oldest retro gaming forum on the internet. The goal of our community is the complete preservation of all retro video games. Started in 2001 as EmuParadise Forums, our community has grown over the past 18 years into one of the biggest gaming platforms on the internet.

Social