User Tag List

Page 40 of 43 FirstFirst ... 30 38 39 40 41 42 ... LastLast
Results 391 to 400 of 426

Thread: XLua extention beta

  1. #391
    Clicker Multimedia Fusion 2
    Retriever2's Avatar
    Join Date
    Jun 2006
    Location
    United States
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    Woo, where to start. You may very well be a trail blazer with the MMFI DLL ... or else everyone's just keeping quiet about it.

    You must always remember that when you access a special member variable like xLeft, you are actually invoking a fairly pricey (relatively speaking) C function with various metaindexing overhead. You should cache the value in a local value if you plan on using repeatedly per frame. Though I'm not sure why class invocations would be faster.

    Are you moving an object between testing overlap? For some reason, if you update an object's coordinates, it will not be reflected in the overlap functions until the next frame. A bit annoying, but easily worked around by leveraging the offset parameters of the overlaps functions. If that's not your problem though, it could be a bug, possibly a bug that I've corrected but not released a build for yet. An example would be great.

    Are you asking about adding say .. different active objects to a combined class? As opposed to totally different object types which groups also don't allow (they split themselves up). Maybe in the future I can add support for groups but I'm not sure how much will need to be changed. It may be fairly straightforward.

    Please, send me an example for each of the specific problems you encountered (and if you can, try to pair it down to a simple test case if you can .. e.g. a frame swarming with objects for performance problems). I'll take a look at it, though admittedly I may not be able to get to it until next week due work and travel.

  2. #392
    No Products Registered

    Join Date
    Mar 2009
    Posts
    18
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    I've actually been caching the variables as much as possible just to make the code easier to type out, though now I'm doing my best to cut back on getting those variables entirely.

    Anyway, I made an example since it should allow you to debug the problem much faster compared to having to figure out what's going on with my engine in its messy state.

    http://larkss.thisisourcorner.net/temp/xlua-bugtest.zip

    While making this, I found out that the issue exists only if the object I'm testing the class against was scaled down during runtime. Kept at original size, all collisions are fine, but when scaled:


    Note that it does work if I keep the single "wall" object in a class and use the testClassGet() function instead:

    ---
    I will work on a speed test Sunday or Tuesday; some college work and family matters need to be tended to. ;>

    Quote Originally Posted by Retriever2
    Are you asking about adding say .. different active objects to a combined class? As opposed to totally different object types which groups also don't allow (they split themselves up). Maybe in the future I can add support for groups but I'm not sure how much will need to be changed. It may be fairly straightforward.
    You are right that is what I'm referring to (not completely different object types like meshing extensions together). That class array is doing the trick for now, but something like class.addObjectClass("object") or newObjectClass("object1","object2",...) would be fantastic. (well obviously adding an entire qualifier would be 10 times better, but the two suggestions could still help in certain scenarios...)

  3. #393
    Clicker Multimedia Fusion 2SWF Export Module

    Join Date
    Sep 2006
    Posts
    1,537
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    Yes I'm guilty of keeping quiet. I saw your MMFI update and it looks mighty impressive, but I've got about 10 pages of code all in the mmf-module formate from previous releases, and it works efficiently right now. If there was some generalized way to convert it to MMFI format I'd certainly do it, but please don't drop backwards compability any time soon!

  4. #394
    Clicker Multimedia Fusion 2
    Retriever2's Avatar
    Join Date
    Jun 2006
    Location
    United States
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    It'll still be there for a while. In terms of raw speed the old interface still has an advantage, but when I took a poll a while back people seemed interested in trading a small amount of speed for a better and safer interface (the external DLL is immune to crashing if you try working on objects that no longer exist).

    But it will be interesting to see the test LarkSS cooks up to see if the performance gap is bigger than I thought.

  5. #395
    Clicker Multimedia Fusion 2SWF Export Module

    Join Date
    Sep 2006
    Posts
    1,537
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    Well I'd say don't make any plans to phase it out :-)
    I'd definitely rewrite my code if it would prove faster but seems like its fine as is

  6. #396
    No Products Registered

    Join Date
    Mar 2009
    Posts
    18
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    What a busy week.

    http://larkss.thisisourcorner.net/temp/xlua-speedtest.zip

    I'd definitely recommend running this in MMF2 HWA making sure that Direct3D9 rendering is enabled, so that the results represent xlua's performance more accurately. You can alter the dot density by tweaking the Spacing values under the Inits script.

    Ah and you have to manually test each frame separately. I was going to have the Enter key swap frames, but when you auto-initialize XLua using the property settings, it causes errors when a new XLua state is binded either from loading a new frame or restarting the current frame/application.


    By the way, it took me quite a bit of guessing to make the MMF Interface equivalent due to no documentation existing except for the one example .mfa. It's a good thing the names you selected for the functions were very straight-forward.

  7. #397
    Clicker Multimedia Fusion 2
    Retriever2's Avatar
    Join Date
    Jun 2006
    Location
    United States
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    Actually, it is still documented, it's just in a separate help file now

    I'll take a look at it later, just got back from a flight and job interview, and all sorts of work and meetings and stuff to attend to tomorrow. What a busy week indeed

  8. #398
    Clicker Multimedia Fusion 2
    Retriever2's Avatar
    Join Date
    Jun 2006
    Location
    United States
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    Hey, I finally got around to testing your second example out.

    Have you by any chance tried enabling LuaJIT for your runs? In testing your example, with LuaJIT disabled, external MMFI ran at about 130fps and internal ran around 150fps. With LuaJIT enabled, external average ran as high as 200fps*, while internal ran about 160fps.

    * Speed seemed to vary a bit between runs, sometimes the average was closer to 160fps

    My next question, if external MMFI was giving crippling performance, is it possible that you're using a debug version of the DLL? If the file size is greater than 150k, it's debug and you'll certainly get crippling performance out of that.

  9. #399
    Clicker Multimedia Fusion 2
    Retriever2's Avatar
    Join Date
    Jun 2006
    Location
    United States
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    http://www.taloncrossing.com/xlua/mmfi.zip

    Here is an updated mmfi.dll (absolutely sure it's not a debug build!), with fixed collision detection for that method.

  10. #400
    Clicker Multimedia Fusion 2
    Retriever2's Avatar
    Join Date
    Jun 2006
    Location
    United States
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: XLua extention beta

    For the performance-minded, I stumbled on this a bit ago and you may find it useful.

    http://www.lua.org/gems/sample.pdf

Page 40 of 43 FirstFirst ... 30 38 39 40 41 42 ... LastLast

Similar Threads

  1. XLua
    By Retriever2 in forum Released Extensions
    Replies: 6
    Last Post: 13th August 2017, 07:42 PM
  2. Extention error with exe
    By Jinxtengu in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 15th October 2012, 03:47 AM
  3. SPC extention question
    By ASD in forum Multimedia Fusion 2 - Technical Support
    Replies: 0
    Last Post: 20th November 2009, 03:25 PM
  4. Lua+ or xLua?
    By Shawn in forum Multimedia Fusion 2 - Technical Support
    Replies: 5
    Last Post: 17th October 2009, 10:55 PM

Posting Permissions

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