Combining Blender Animation with Sketchup in Studio

Created a nice video, document or a translation of another document? Share it here for licensed users.
User avatar
leminilab
Licensed User v1.5
Licensed User v1.5
Posts: 818
Joined: Sat Nov 14, 2009 6:41 pm
Location: Vitry-sur-Seine
Has thanked: 25 times
Been thanked: 23 times
Contact:

Hi, Dave,

I couldn't come back on my attempts to export from Blender to Thea yet.

But I sure will look at your video again. Curve export seems a good news: did you manage to export a curve ?

Here's the curve though: to get the result I wanted, I animated both the start and end of the curve.

Thanks again for your interest and your help and have a nice day, :wave:
Nicolas
Attachments

[The extension blend has been deactivated and can no longer be displayed.]

Live every day as if it were your last and then some day you'll be right.
DavePSB
Licensed User v1.5
Licensed User v1.5
Posts: 1291
Joined: Wed May 12, 2010 8:56 pm
Location: France
Has thanked: 13 times
Been thanked: 16 times

Thanks for the .blend.

I am not a beta tester, so do not have access to unreleased updates that might export curves directly.

However, after a bit of modification to your animation in the .blend, and adding the build modifier, I was able to export the building bevel without much problem. In the process, I have learned a bit more about the plug-in.

However, you will see that I had to delete the animation of the bevel ending (because of limitations with the build modifier), so in my result, the worm only grows continuously in one direction (and its tail never gets shorter). This of course is not the result you want, but it did prove the export procedure. The key is to convert the curve to a mesh at a point where 100% of the bevel length is showing. Then the build modifier will build 100% of the bevel length. If you convert the curve to a mesh when no bevel is showing, you get nothing.

The problem now is the fact that the build modifier does not have anything like start and end options. It only builds the mesh from beginning to end (or in reverse), period. So unless another technique comes along (or the updated plugin supports curves), I don't think we would achieve the animation effect you are looking for.

Anyway, still learning a lot.
Anim.gif
Anim.gif (413.7 KiB) Viewed 351 times
Win 10
i7-9700K,3.6GHz,32Gb,
RTX2060Super, 8Gb, 442.19
SUMake2015 (15.3.331)
TheaForSU (1.5.09.547.1462)
Thea Studio (1.5.09.1462)
SUMake 2017 (17.2.2555)
TheaForSU (2.2.954.1860)
Blender 2.79, Plugin 1.5.8.760.1455
Blender 2.8x
Revised 14 Feb 2020
DavePSB
Licensed User v1.5
Licensed User v1.5
Posts: 1291
Joined: Wed May 12, 2010 8:56 pm
Location: France
Has thanked: 13 times
Been thanked: 16 times

Sudivided the curve a bit and merged with SU scene.
Animation3.gif
Animation3.gif (2.33 MiB) Viewed 351 times
Win 10
i7-9700K,3.6GHz,32Gb,
RTX2060Super, 8Gb, 442.19
SUMake2015 (15.3.331)
TheaForSU (1.5.09.547.1462)
Thea Studio (1.5.09.1462)
SUMake 2017 (17.2.2555)
TheaForSU (2.2.954.1860)
Blender 2.79, Plugin 1.5.8.760.1455
Blender 2.8x
Revised 14 Feb 2020
User avatar
leminilab
Licensed User v1.5
Licensed User v1.5
Posts: 818
Joined: Sat Nov 14, 2009 6:41 pm
Location: Vitry-sur-Seine
Has thanked: 25 times
Been thanked: 23 times
Contact:

Hi,

Dave, I just watched your video again: I think I can do it... But then again, it doesn't seem too user-friendly so far...

I'm getting an error message.
Here's the console output:

"Inspecting command line
Executing command line
GenerateSun: Position [-0.0217807 -0.999724 -0.00883382 0 0.926427 -0.023504 0.37574 0 -0.375844 0 0.926683 0]
Finished in 0 seconds!
Inspecting script "C:\Users\leminilab\Desktop\Nouveau dossier\Blender_to_thea\exports\untitled_Camera.ipt.thea"
Executing script "C:\Users\leminilab\Desktop\Nouveau dossier\Blender_to_thea\exports\untitled_Camera.ipt.thea"
Failed during parsing message "Merge C:\Users\leminilab\Desktop\Nouveau dossier\Blender_to_thea\exports\~thexport\frames\untitled_Camera_f0001.xml 0 0 0 0"
Error at line 1: message "Merge C:\Users\leminilab\Desktop\Nouveau dossier\Blender_to_thea\exports\~thexport\frames\untitled_Camera_f0001.xml 0 0 0 0"
Finished in 0 seconds!"

Could someone tell me what's wrong? :think:
Live every day as if it were your last and then some day you'll be right.
DavePSB
Licensed User v1.5
Licensed User v1.5
Posts: 1291
Joined: Wed May 12, 2010 8:56 pm
Location: France
Has thanked: 13 times
Been thanked: 16 times

I reported what I think is a bug, but haven't heard back. I'm not sure off hand whether this is the same problem. Basically, unless you export a single dummy frame first, my video will fail because by going straight to exporting the animation (like you should do normally), the wrong directory structure is created (it creates something like \~thexportFrames rather than \thexport\Frames), and then things crash because it can't find a directory. I did not have the problem in the video because prior to the video, I had been messing around with everything trying to get it to work. During the messing around, I must have managed to get something to create the correct directory structure (by accident). So, just to be safe, just export a dummy frame before exporting the animation.

Also, I did try to get your start and end beveling curve to Thea using the latest version of the plug-in (since it supports curves), and it DID work, but only if at least a tiny bit of the bevel is created in Frame 1. Then the worm grows from the front and eats itself at the tail no problem just like your video. With the setup I was using, the curve in Frame 1 existed but had no faces to export. The plug-in apparently does not like exporting null-like object, so crashes. The fix was just to set the start bevel slider to 0.975 instead of 1.0 so the very start of the worm actually existed in Frame 1, then the animation exported OK. I never got round to finishing all that though. But the error message in this case has a line that complains about "calc_normals". This does not seem to be the same as your error message. Interestingly, if you render animation from within Blender, it DOES work, even if the start bevel slider is set to 1.0 in frame 1. This is very confusing now.

Not much help I guess. Are you testing with the same .blend that you posted earlier in this thread?
Win 10
i7-9700K,3.6GHz,32Gb,
RTX2060Super, 8Gb, 442.19
SUMake2015 (15.3.331)
TheaForSU (1.5.09.547.1462)
Thea Studio (1.5.09.1462)
SUMake 2017 (17.2.2555)
TheaForSU (2.2.954.1860)
Blender 2.79, Plugin 1.5.8.760.1455
Blender 2.8x
Revised 14 Feb 2020
User avatar
leminilab
Licensed User v1.5
Licensed User v1.5
Posts: 818
Joined: Sat Nov 14, 2009 6:41 pm
Location: Vitry-sur-Seine
Has thanked: 25 times
Been thanked: 23 times
Contact:

Well ocnfusing it is indeed.

No, I elected on starting with a new blank scene in Blender 2.76 with the latest plugin installed.

I think we should be able to see if the Animation and mesh animation export are toggled on or off in the Thea tool panel. Also, I wonder if the error message within Blender are customizable: I think it would help to have error messages that are not lines of code...

I need to try again replicating this little animation: your success makes me envious! :D
Hopefully, I'll have more time to play around...

Thea is amazing as well as Blender and Sketchup: I really want to be able to get the best of all worlds! :thumbup:
Live every day as if it were your last and then some day you'll be right.
DavePSB
Licensed User v1.5
Licensed User v1.5
Posts: 1291
Joined: Wed May 12, 2010 8:56 pm
Location: France
Has thanked: 13 times
Been thanked: 16 times

Here's a long shot. If you load the attached .blend into a clean empty subdirectory, change ONLY the render Output path to something on your machine, and then hit the Animation button (without touching anything else first), does the full animation start rendering within Blender?. The first frame is black for some reason, and I think I saw a bug report to this effect, but the rest of the frames should render. If that works, maybe you can start from there, then adapt any success to your actual .blend. The animation should go pretty fast as the resolution and number or samples are set low.

I don't know if the Blender renderer choice (Thea Render, Blender Render, Cycles) is saved in my .blend, so make sure the Thea plugin is selected, and I'm still using Blender 2.75.
StartEndBevelAnimation02.zip
(84.07 KiB) Downloaded 18 times
Win 10
i7-9700K,3.6GHz,32Gb,
RTX2060Super, 8Gb, 442.19
SUMake2015 (15.3.331)
TheaForSU (1.5.09.547.1462)
Thea Studio (1.5.09.1462)
SUMake 2017 (17.2.2555)
TheaForSU (2.2.954.1860)
Blender 2.79, Plugin 1.5.8.760.1455
Blender 2.8x
Revised 14 Feb 2020
User avatar
Rombout
Posts: 15255
Joined: Tue May 12, 2009 12:42 am
Location: Curacao, Netherland Antilles
Has thanked: 37 times
Been thanked: 324 times

This is a long shot, but doesnt the merg code need a single apostrophe for and after the address of the file?
I think windows needs this as well. Ive also noted this to the developper of blender, havent tested it in a while.

Below is example of code that works on mac

Code: Select all

message "Load /users/romboutversluijs/desktop/thea_1355/weld test.scn.thea"
message "Merge '/users/romboutversluijs/desktop/thea_1355/instance error_rv1371.scn.thea' 0 0 0 0 0 0 0" 
message "./Scenes/Active/Cameras/## Current View ##/Make Active"
message "Load /Users/romboutversluijs/Library/Application Support/Thea Render/Presets/02. Unbiased (TR2).xml"
set "./Scenes/Active/Render/Max Samples" = "10"
message "Render"
message "SaveImage test.png"


DavePSB
Licensed User v1.5
Licensed User v1.5
Posts: 1291
Joined: Wed May 12, 2010 8:56 pm
Location: France
Has thanked: 13 times
Been thanked: 16 times

Below is a line from one of my working .ipt files. It seems the same as leminilab's regarding quotes, so I think Apple is slightly different. But I DID notice that the first merge parameter is 0 in leminilab's case, whereas for mine it is 4 (and sometimes 5 depending on what I am doing).

This reminded me of another bug I never reported: If in the Thea Merge Scene panel, you select Model/Merge Name Collision Replace Mesh and THEN select the merge file, it clears all the merge check boxes. You must select the merge file first, THEN set the merge check boxes.

message "Merge E:\MyDataK\Computer\TheaRender\__DJMTests\BlenderSUThea\BuildBevel02\~thexport\frames\Curve_DJM04_Camera_f0004.xml 4 0 0 0"
Win 10
i7-9700K,3.6GHz,32Gb,
RTX2060Super, 8Gb, 442.19
SUMake2015 (15.3.331)
TheaForSU (1.5.09.547.1462)
Thea Studio (1.5.09.1462)
SUMake 2017 (17.2.2555)
TheaForSU (2.2.954.1860)
Blender 2.79, Plugin 1.5.8.760.1455
Blender 2.8x
Revised 14 Feb 2020
Post Reply

Return to “Tutorials & Translations”