MSPhysics 1.0.3 (16 October 2017)

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Anton_S » Thu Sep 07, 2017 8:33 pm

Faust, replay doesn't record transformation of vertices. There is nothing you can do with it yet, but is a good request.
0

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby RobiBue » Tue Sep 19, 2017 8:58 pm

I have an odd result with a test I've been trying to get to work:
I have two aluminium pieces, connected through two aluminium bars.
One aluminium piece is static with two hinge joints (each connected to one bar).
One of the hinge joints I have set up as an angular spring to dampen the fall.
The other aluminium piece is connected to two hinge joints, each on the end of the two bars.

My problem is, the system starts to wobble after 10 seconds :( , and after 30 seconds it spins out of control :o .

what am I doing wrong?

attached is the SU15 model with MSPhysics 1.0.2 and AMS_lib 3.5.2
MSPhysics hinged test.skp


edit: I wanted to attach a spring (instead of using the angular spring hinge) but I believe that springs are fixed and non-movable) and somehow I can't implement this idea.
with spring.png
0

RobiBue 
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Anton_S » Wed Sep 20, 2017 5:43 am

RobiBue wrote:My problem is, the system starts to wobble after 10 seconds :( , and after 30 seconds it spins out of control :o .

what am I doing wrong?

If you set simulation solver model to iterative 64 passes and update timestep to 1/120, the wobbling should be significantly reduced.
RobiBue wrote:edit: I wanted to attach a spring (instead of using the angular spring hinge) but I believe that springs are fixed and non-movable) and somehow I can't implement this idea.

Don't do that. Spring joints are for linear motion, not for angular. Either use angular spring, or since you want to dampen the whole thing, simply change hinge mode to Angular Friction and increase the friction parameter, to say, 4000000.
1

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby RobiBue » Wed Sep 20, 2017 1:11 pm

Anton_S wrote:If you set simulation solver model to iterative 64 passes and update timestep to 1/120, the wobbling should be significantly reduced.

Thank you very much Anton, this helped :)

Anton_S wrote:Spring joints are for linear motion, not for angular. Either use angular spring, or since you want to dampen the whole thing, simply change hinge mode to Angular Friction and increase the friction parameter, to say, 4000000.


This worked great, although I think I found the solution I was somewhat looking for using servos with an angular limit :D
Here's what I was aiming for
MSPhysics hinged test2.skp
0

RobiBue 
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby TDahl » Sun Oct 08, 2017 10:50 pm

I'm hoping for advice on how to improve a model that attempts to simulate a thin flat flexible cable that is coiled or wrapped within a hollow rotating drum. Despite hours and hours of experiments, I cannot avoid SketchUp crashing (bugsplat) after about 2 to 2.5 rotations of the drum. I'm using MSphysics 1.0.2 with SketchUp Pro 2017.3.

[Update on Wednesday morning: As an experiment I changed the collision shape of the cable strips (see below) from compound to box, and that often avoids the crash. Sometimes the simulation even lives long enough to run 7 rotations clockwise and then 7 rotations counter-clockwise. Gravity can be enabled at about 1/300 time steps and higher, even.]

Here is a copy of the model file:
Viking Lander for SSAA FCC Animation Bare.skp


And an image of the general arrangement:
MSphysics Flat Cable Bend Issue.jpg


The model is scaled up 10x from some actual hardware I am trying to simulate (scaled in the hope of avoiding numerical issues in the simulation caused by the very thin cable). The cable (in the model) is about 30 inches wide and 0.1 inch thick. I have modeled the cable as a series of about 250 thin strips hinged to one another. One end of the cable is anchored to a hinge on a stationary hub (set to be static, tinted green in the above image) at the center of the drum. The other end of the cable is anchored to a hinge that is on the wall of the hollow gray drum. In its initial configuration the cable wraps three times around the stationary hub. The goal is to drive a motor to rotate the drum clockwise six or so full rotations. The flexible cable is intended to gradually unwrap from around the stationary hub, accumulate loosely around the inner face of the drum after three or so rotations, and then re-wrap about three times around the stationary hub in the opposite direction from the initial conditions. There is one motor controller - click it to the left (-1) to rotate the drum in the clockwise direction.

I am not very fussy about the hinge joints between the individual cable segments; the goal is to represent a lightweight cable that can flex a fair amount, with a mild tendency to straighten. I have tried friction and both types of spring hinges, with all sorts of parameter settings. Some hinge types make the model explode (which is comical to watch). Others seem to more-or-less behave OK except the cable is not as flexible as I would like. And of course the crash of the software; I'm not sure what aspect of the physics simulation is causing that - hinges or collisions or what. I have disabled gravity and friction for all active bodies. I have tried various settings of continuous-collision and Update-Timestep; the simulation usually survives longer (in simulated time) with higher time steps (e.g., 1/240, 1/480 etc.).

Both the cylindrical stationary hub and the hollow drum are modeled as a set of solid groups or components, with the individual pieces being convex. (The stationary hub's segments have some concavity due to two small raised flanges. I'm not sure if this is causing trouble. I used MSphysics feature to show collision wireframes, and what is rendered looks OK to me. I could delete those flanges.) There are also three thin curvy bend-guards to prevent the flexible cable from being bent too tightly at either end. Those guards are also modeled as a set of convex elements.

As a plus I would also like to eliminate the narrow visual gaps between adjacent cable strips (which seemed necessary to avoid corners of adjacent strips colliding and thus preventing joint bends). However, the main goal is to avoid the software from crashing as the simulation executes.
0

TDahl 
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Anton_S » Thu Oct 12, 2017 9:37 pm

Hello TDahl,

First of all, very professional work here, in a sence of understanding how to use the plugin despite the lack of documentation on it. Great job!

I'm not sure what is causing the crash. I think that the physics engine has a limit on how much joints it can control at once. I will look into this bugsplat issue when I find the time.

Meanwhile, there are a couple of things you can do to improve behavior of cable and performance:
  1. Because you are relying on a small timestep (1/300), reducing solver model, to 4 iterations for example, would improve the performance by a good factor. Solver model basically controls the stability of joints. If your timestep is small, reducing solver model would alter the stability joints by an unnoticeable factor.
  2. Specificating the collision shape of "FCC Segment Instance" to Box should improve the performance as well. I assume you already did that for your the edited model, but in case you haven't, here is an easy way to do it for all of them: Because all your cable segments have the same name, you can assign a box shape to one of the segments and use the Assign Props to All with Name button, within the MSPhysics UI, to assign alike properties to all instances with the same name.
  3. Because all joints are flexible, you can simply rely on a Fixed joint, rather than Hinge. This would make the entire cable more stiff and of course improve performance.
I eddied your model, containing all the addressed suggestions and attached it below.

Also, if you change a joint within one of the wire segments, which also adds it to all other component instances, you can re-interconnect the segments with their joint by pasting this command into Ruby Console:
Code: Select all
id = 646194 # Change this to desired joint ID.
instance_name = 'FCC Segment Instance' # Change this to instance name
ids = [id]
Sketchup.active_model.start_operation('OP', true, false, false)
Sketchup.active_model.entities.each { |e|
  if (e.is_a?(::Sketchup::ComponentInstance) || e.is_a?(Sketchup::Group)) && e.name == instance_name
    e.set_attribute('MSPhysics Body', 'Connected Joints', ids)
  end
}
Sketchup.active_model.commit_operation

That's the code I used to interconnect the Fixed joints with their segments.

Once again, great work, TDahl!

Best regards,
Anton
0

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby TDahl » Sat Oct 14, 2017 3:51 am

Hi Anton, thank you for the compliment. Your extension and its physics engine are fantastic and (sometimes) maddening. ;) One area I really do not understand is how the extension works for connecting joints. In some situations it behaves fine: I click on a joint which turns blue, I shift-click on a body which turns green, done. Repeat the same click and shift-click sequence on another joint and another body, done. That's great.

But other times, joints seem to auto-connect to surprising bodies, or change their connections when I attempt to re-connect different joints. I recall in older versions of the plugin there was some kind of connect-closest-joint feature which I cannot now locate in the GUI. I wonder if there is some remnant of that which activates under certain circumstances? Perhaps joint connections are troublesome when there are many joints and bodies in close proximity (which I am doing lately)? Here is a screen capture with a body selected, showing that dozens of joints have become connected to it:
Joint Connect Behavior.png

The kind of maddening behavior I'm experiencing tonight is: I click a joint (turns blue), I shift-click a body (turns green). OK. Do that two or three times with nearby joint-body combinations. OK. Then as a sanity-check return to the first combination: click on the first joint, and automagically it is now connected to some other body or bodies, not the one I had set a few moments earlier.

I must not understand how to operate the connect-joint GUI. I'm on a Mac with OS 10.12.6. When the joint connection tool is activated, the hint along the bottom of the SketchUp workspace window says to use CTRL, SHIFT, or both to connect/disconnect. The CTRL modifier causes a pop-up menu to appear with two choices, Disconnect all joints, and Exit. Is that expected? The SHIFT modifier does not always allow me to select the desired object, which I don't understand. In the following screen capture I cannot select the body which has a dashed-magenta outline:
Unable to select the dashed-magenta body.png

In case it's hard to see, the dashed-magenta body is just below the green-outline body. I am trying to disconnect the selected (blue) joint from the green-outline body and connect it to the dashed-magenta outline body. Shift-clicking on the dashed-magenta body simply causes the dashed-magenta outline to appear and disappear, with each shift-click. The green-outline body remains green.

Shift-clicking on the green body yields confusing results which would take a page to describe, so I will stop here for now. I really hope to understand how I can be in 100% total manual control of how joints and bodies connect. There must be some limitations in what can connect to what that are not apparent in the GUI. I realize that the dashed-magenta outlines represent potentially-connectable objects. Why are only some objects potentially connected, and not others? (Even for a set of objects that are all at top-level in the model hierarchy.)

By the way, thanks for the tip about using a fixed joint rather than a hinge. However, the fixed joint has behaviors that make me prefer the hinge joint for this application. The fixed joint results in a much floppier flexible simulated cable (at least on my computer) compared to a hinge/angular-spring), and I prefer the somewhat stiffer behavior with the hinge. Also, if the simulation lives long enough for 3 to 5 rotations with the fixed joint the cable strips eventually begin to tilt and oscillate sideways and eventually explode the model (which looks pretty cool but is not exactly the goal!).
0

TDahl 
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Anton_S » Sun Oct 15, 2017 12:20 am

TDahl,

Connect closest joints option is now a default functionality of joint connection tool. It's difficult to explain the behavior of a joint connection tool. That said, it needs a big overhaul. I will work on it after I finish with my other plugin.

Regards,
Anton
0

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby pilou » Sun Oct 15, 2017 10:48 am

Hello Anton

Can we made yet this sort of thing inside MSPhysics ?

0
Frenchy Pilou
Is beautiful that please without concept!
Speedy Galerie
User avatar
pilou 
Top SketchUcator
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Anton_S » Mon Oct 16, 2017 3:44 am

Pilou, I think that light animation can easily be achieved with MSPhysics and TwilightRender/Skindigo/Kerkythea. Simply attach a lamp to a BallAndSocket joint, play simulation with record enabled, and then export to desired rendering format. Although in this video, a different approach is used, I'm certain that a rendering software would guarantee better results.
0

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby pilou » Mon Oct 16, 2017 9:34 am

Thx for the answer! :enlight:
0
Frenchy Pilou
Is beautiful that please without concept!
Speedy Galerie
User avatar
pilou 
Top SketchUcator
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Anton_S » Mon Oct 16, 2017 11:59 pm

Pilou,

I just made a demonstration of that in MSPhysics and free Twilight: https://drive.google.com/open?id=0B3qg8 ... Ud1N0FNXzg

Free Twilight also allows rendering in High+ mode and large resolutions. I used small resolution just to get it to render fast.

This can also be done with Kerkythea but in my opinion Twilight is a better rendering software. When I have time I will do a tutorial of how to set it all up. It shouldn't be to difficult though.

The model is attached below.

Regards,
Anton
0

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby Anton_S » Tue Oct 17, 2017 1:29 am

Announcing version 1.0.3: http://www.rubydoc.info/github/AntonSyn ... ANGELOG.md

@rick149 I added an option to hide/show selected entity as you requested.

@TDahl I improved the joint connection tool. Whenever you perform connection with alike instances, it will ask you whether to apply same connection to all instances, which will simplify the work you will have to do when dealing with chains or threads. I also improved the behavior of a Fixed joint. Now, if you use the version of your Viking Lander model that I posted, that contains Fixed joints, the wobbling of the segments should be significantly reduced. Edit: Also, if you change Fixed joint stiffness to 0.99, the wobbling would no longer be there.
1

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby pabloarias » Sat Oct 21, 2017 11:31 am

Hi Anton.

I want to congratulate you for this awesome plugin. In your ToDo list you include Cloth (I think as a material) and Soft bodies, and user mesh collision. When do you think those functions will be ready?
0

pabloarias 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby Anton_S » Sun Oct 22, 2017 4:07 am

Hi, pabloarias,

Cloth and soft bodies (on the ToDo list) is something that I might implement in the long-term. The physics engine that I use doesn't have a functional cloth/soft-body system yet.

Other than that, I am writing a separate cloth simulation plugin (with my own physics engine). I've been working on it for quite a while now and I am looking forward to finishing it as soon as I can.

Regards,
Anton
5

Anton_S 
PluginStore Author
PluginStore Author
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby Pixero » Mon Oct 23, 2017 8:13 am

Anton_S wrote:Other than that, I am writing a separate cloth simulation plugin (with my own physics engine). I've been working on it for quite a while now and I am looking forward to finishing it as soon as I can.


Whohoo! If you need someone to test it just let me know. :thumb:
0
User avatar
Pixero 
Premium Member
Premium Member
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby pabloarias » Mon Oct 23, 2017 1:50 pm

Pixero wrote:
Anton_S wrote:Other than that, I am writing a separate cloth simulation plugin (with my own physics engine). I've been working on it for quite a while now and I am looking forward to finishing it as soon as I can.


Whohoo! If you need someone to test it just let me know. :thumb:


And I could be a tester for that plugin, too. :-)
0

pabloarias 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby yasharozov » Sun Oct 29, 2017 2:21 am

Hi,
I'm having a problem with joining a group to a motor joint. I have a complex object, a tank...
I drill down to one of the wheels and draw a motor joint at it's center. Next step is id like to join the motor joint to the wheel group. Once I select the joint connection tool and attempt to select the wheel group, the whole tank reappears, i.e. I am no longer in the wheel group so I cant attach the wheel and the motor joint....help....in other words...once I click the joint connection tool and move close to my isolated group the view switches to all the levels above it regrouped without me having access to the relevant group...ive attached the file I'm working on..
0

yasharozov 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby pcberdwin » Thu Nov 02, 2017 8:26 pm

Will your cloth sim plugin be available from your Google Drive archive?
Also, I've been eagerly yet patiently waiting for cloth and fracture/split features and know you are just one guy so I totally respect and appreciate all that you do.
0
User avatar
pcberdwin 
 

Re: MSPhysics 1.0.2 (19 July 2017)

Postby Patrick » Fri Nov 03, 2017 8:34 am

Anton_S wrote: ... I just made a demonstration of that in MSPhysics and free Twilight: https://drive.google.com/open?id=0B3qg8 ... Ud1N0FNXzg
Free Twilight also allows rendering in High+ mode and large resolutions. I used small resolution just to get it to render fast....


Hello Anton,
thank's for the answers (and sorry for my poor english !).

Ok for the light with Twilight (render = image); but for the movie with Msphysics like your example ? How to make this video ?

Patrick
0
La CAO sans se casser la tête ? FreeCAO la CAO toute en vidéo.
User avatar
Patrick 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby rick149 » Wed Nov 08, 2017 7:40 am

Gday
Can I control the order in which the sliders appear in the MSPhysics Control Panel?

OKA1.jpg


MSphysics is amazing.

This is an animated 3D model of my real homebuilt OKA 4WD truck modified as a go anywhere comfortable offroad motorhome. It has taken us to the isolated wilderness throughout Australia over the last few years: ...deserts, mountains, rivers and coast.

OKA2.jpg


the model, thanks to MSPhysics is a true detailed representation of the truck with 4WD, steering and suspension that demonstate the capabilities of the real vehicle as a true earth cruiser well.

OKA3.jpg


when i am finished I plan to put it all on an interactive website.

Thanks for the MSPhysics extension; ...with little doco, it has taken a lot to learn but learning all the different properties by suck it and see is better in the long run, especially after I found that once you know the various parts of the interface, they are very consistent and predictable.

When you get it right and learn its limits it is very stable makes animation and video production so easy and precise.
2

rick149 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby faust07 » Wed Nov 08, 2017 11:45 am

@Patrick: Twilight has an "Animation Editor" under "Twilight Render V2" in the extensions pull-down menu. There you can select quality, resolution, MSP Replay output etc. It could be helpful to test which scenes you include ore exclude into an animation in scene settings.

@rick149: great detailed model! Can't wait to see it in action.
0

faust07 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby faust07 » Wed Nov 08, 2017 8:40 pm

Hi Anton,
Do you see a possibility that "non-collidable" set objects will be ignored by the Buoyancy Plane?
0

faust07 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby TDahl » Fri Nov 17, 2017 5:14 am

Hi Anton, I'm hoping you may be able to diagnose an issue with recording MSphysics animations. With an evolved version of my model posted above containing a flat electrical cable that wraps around the interior of a hollow drum, SketchUp crashes (bug splat) when I click the Reset Simulation button after recording anything more than a few hundred to perhaps a thousand frames. My goal is to allow the simulation to run for about ten thousand frames (and then export 1920x1080 PNG frame files at a time scale of ~13, so that I end up with 700 to 800 actual PNG files). In order for the simulation to not encounter object penetration and collision problems the Update Timestep needs to be about 1/420 or smaller (which results in a large number of computed frames for a given real time sequence).

I would dearly love to be able to record a simulation where the drum (who's motor controller I activate manually right as the simulation starts) is allowed to rotate nearly 7 times, then the controller is set to zero and the simulation is allowed to settle for a bit. However, the MSphysics recorder seems to cause the extension and all of SketchUp to crash when resetting the simulation (clicking the "<<" button) after more than about 1/2 to 1 revolution of the drum.

I have tried SketchUp 2016.1 and 2017.3, with similar results. I am running this on an iMac with 32GB of memory. The SketchUp process grows to between 9GB and 10GB by the time seven rotations of the drum have occurred and 9700 to 10000 frames have been computed (and I'm ready to click the Reset "<<" button). The computer has sufficient memory to support this, though the simulation eventually runs quite slowly as the process expands memory bit by bit by bit, only doing a few frames every few seconds. My last run took about 2.5 hours of elapsed time to compute those seven rotations. That amount of compute time would be OK if the result was a usable recording. :-)

By the way, a few weeks ago you had posted a revised version of my flexible cable model that uses fixed joints (between the ~250 cable segment objects) instead of hinges (as used in my versions of the model). I have tried that fixed-joint approach, but the resulting floppy behavior of the cable is not as appealing to me as the behavior that occurs with the hinge joints, so I prefer to use the hinges.
0

TDahl 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby rick149 » Fri Nov 17, 2017 11:16 pm

rick149 wrote:Gday
Can I control the order in which the sliders appear in the MSPhysics Control Panel?


I find the order of controls varies when I edit/change joints but cannot see the logic behind it.

It does not always seem to be controlled by the order in which joints are created and/or when they are edited.

My model is managed as an evolving assembly of models and components including joints, some with controllers, some without and some with keyboard control.

I have the design of the assembled model and the assembly procedure down pat now so that when I change and re-import the different parts, all the joints and their controls work perfectly but I cannot consistently maintain their order in the panel after various changes are made.

Ideal would be... can I vary the panel order after the joint controllers are in place?
0

rick149 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby luckyvac » Tue Nov 21, 2017 9:19 am

Hi Anton, I realized an unstable gyroscope. The rotor is controlled with the spacebar. Can we make it stable? thank you :)

episode 2
Hello Anton, I can not regulate MSphysique so that the bearings are not transparent. what to do. thank you
0
Last edited by luckyvac on Fri Nov 24, 2017 10:08 am, edited 1 time in total.
User avatar
luckyvac 
Premium Member
Premium Member
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby djhg » Thu Nov 23, 2017 8:48 pm

I need to create a very floppy long mattress/cushion and drape it realistically over the seat, arms, and back of a piece of furniture. There's a tutorial with french subtitles and no audio about cloth simulations, but my french isn't good enough and I am looking to learn more. If anyone can point me in the direction of some instruction, I'd appreciate it.
0

djhg 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby tmixer1 » Sat Nov 25, 2017 3:26 am

Would you please add ropes to your to-do list? Thank you
0

tmixer1 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby nasser321 » Tue Dec 05, 2017 9:52 pm

the link of (Compatibility and Requirements//AMS_Library 3.5.0+) say " The requested topic does not exist."
So go to link (viewtopic.php?t=55067) to get it
0

nasser321 
 

Re: MSPhysics 1.0.3 (16 October 2017)

Postby surfmike » Mon Dec 25, 2017 10:55 pm

Hi all and Happy Christmas!

I have one issue to solve...
- I have one group of objects that shall move linear in one direction.
- I have another group of objects that shall move linear in 180° opposite direction simultaneously.
Is that possible to achive with just one slider controller?

Edit: I solved it myself. 2 pistons (one turned 180°) , same name, 1 controller.
0

surfmike 
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 

PreviousNext


 

Return to Plugins

Who is online

Users browsing this forum: Bing [Bot], TBoy and 8 guests

Visit our sponsors: