[Plugin] ShadowProjector

Re: [Plugin] ShadowProjector

Postby barney_and_ted » Thu Jan 15, 2015 9:30 am

Hello TIG,

Your plugin is very useful :thumb:
The face name is automatically create in the report ! Is it possible to change it ? In order to have more convenient name.

Thank you
0

barney_and_ted 
 

Re: [Plugin] ShadowProjector

Postby djh » Sun Mar 08, 2015 4:51 pm

Dear TIG,
Your plugin looks like just what I need - to export vector (dwg or dxf) with shadows. I am drawing technical illustrations with fine lines and shadows. When I export them as a jpg or tiff and shrink them down, the lines get broken and don't print well. But, I can't figure out how to use your plugin. I keep getting this message even when I select a face. "You must Pre Select at least ONE Suitably Oriented Face!" I haven' projected a shadow yet. I even tried with some very simple models, but...
Can you please help me?
DJH
0

djh 
 

Re: [Plugin] ShadowProjector

Postby driven » Sun Mar 08, 2015 5:09 pm

shad_proj.gif
1
learn from the mistakes of others, you may not live long enough to make them all yourself...

driven 
PluginStore Author
PluginStore Author
 

Re: [Plugin] ShadowProjector

Postby djh » Mon Mar 09, 2015 9:55 am

Thank you very much, Driven and TIG. Also, I exploded all the components and groups. It works wonderfully.
0

djh 
 

Re: [Plugin] ShadowProjector

Postby TIG » Mon Mar 09, 2015 11:42 am

You don't need to explode everything.
But you do need to select the face[s] to receive the shadow outlines.
This means they do need to be in the same context, but then you could edit the container and select the face ?
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby djh » Tue Mar 10, 2015 9:30 am

This means they do need to be in the same context, but then you could edit the container and select the face ?[/quote]

What does it mean "in the same context"?
0

djh 
 

Re: [Plugin] ShadowProjector

Postby djh » Tue Mar 10, 2015 9:38 am

Having problems, even when I redrew the model as simply as possible.
0

djh 
 

Re: [Plugin] ShadowProjector

Postby TIG » Tue Mar 10, 2015 12:44 pm

Thanks ofr the example SKP.
I do agree that it fails.
But the info I get from the Ruby Console is helpful to see what is wrong.
I'll look at how it might be recoded to resolve the issue.

Incidentally, you model contains some reversed faces inside the grouped 'walls' and several bits of hidden geometry [View > Hidden Geometry > ON] around the tops/ends of some walls.
Although they shouldn't cause issues it's good practice to tidy your model as you go.
With them gone it still fails, so they're not the cause of the issue...
I will fix it. :?

Watch for updates/announcements...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Tue Mar 10, 2015 4:03 pm

Here's v1.5

Download

It fixes a problem which resulted from instances [groups/components] sat directly 'on' a shaded-face, and sometimes not casting a shadow below them.
It should now be more robust and cope with raw geometry, groups and components placed directly on top of the shaded-face.
It works properly with @djh's example SKP ! :D
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Wed Mar 11, 2015 2:39 am

Thanks for the update. I'm still getting unexpected results. See the attached screen shot. The edges of the projected "shadow" are 500 meters long and extend down below the face on the ground plane and away from the sun.

Screenshot - 3_10_2015 , 8_42_48 PM.png
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Wed Mar 11, 2015 10:30 am

Thanks Dave, I too have seem some issues and I'm working on a fix... :roll:
The face should be 1km long NOT 500m !! ;)
1
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Wed Mar 11, 2015 11:09 am

Half is better than none.
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby djh » Wed Mar 11, 2015 11:18 am

TIG, thanks for the advice to clean up the model.

I'm sorry, I still got the same results. I don't know how you were able to do it with the same model. Also, you mentioned before, "This means they do need to be in the same context, but then you could edit the container and select the face?" What does it mean "in the same context"?
0

djh 
 

Re: [Plugin] ShadowProjector

Postby TIG » Wed Mar 11, 2015 12:32 pm

I'm working on a fix...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Thu Mar 19, 2015 6:06 pm

Here's v2.0

Download


It is completely rewritten to be faster ad more robust...
1
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Mon Mar 23, 2015 3:37 pm

Here's v3.0

Download

Along with ignoring Hidden faces/objects and those assigned OFF Layers, it now respects transparent faces [<70% opacity] which won't cast shadows, and similarly faces with the default-material faces within a container that itself has a transparent material and which doesn't then cast a shadow etc.
Objects with cast/receive shadows 'unchecked' settings are now fully respected in the shadow analysis.
Faces which shade themselves [because they face away from the sun] are automatically assigned 100% shading with no further analysis...
A glitch with report writing if type was 'lines' is now resolved.
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Tue Mar 24, 2015 12:58 am

Latest version installed. Get this in console when trying to run the tool.

Error: #<NoMethodError: undefined method `each' for nil:NilClass>
C:/Users/Dave/AppData/Roaming/SketchUp/SketchUp 2015/SketchUp/Plugins/TIG-ShadowProjector/TIG-ShadowProjector_Code.rb:127:in `new'
C:/Users/Dave/AppData/Roaming/SketchUp/SketchUp 2015/SketchUp/Plugins/TIG-ShadowProjector/TIG-ShadowProjector_Loader.rb:18:in `block in <module:ShadowProjector>'
SketchUp:1:in `call'
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Tue Mar 24, 2015 11:56 am

Obviously it shouldn't do that :?
Did you have a face preselected ?
I'm on to it... :geek:
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Tue Mar 24, 2015 12:00 pm

I did have a single face, correctly oriented selected. I tried it first on a chair model I was working on at the time when I got that message. I quit SU and restarted. Then tried it with a simple box in a component and an ungrouped face. Same result.
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Tue Mar 24, 2015 12:06 pm

Here's v3.1

Download


It fixes a glitch caused by a simple typo.
The test for 'receive-shadows' for a container being unchecked was inadvertently being run even if the selected face were in the model entities, which of course cannot have that set !
Now resolved.
Thanks Dave for feedback...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Tue Mar 24, 2015 12:11 pm

Glad to help, sir. I'll give it a try when I get home from work and let you know.

d
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Wed Mar 25, 2015 11:34 pm

I tried it on a simple box and face. It worked fine. Tried it on a slightly more complicated model and it splatted, twice. I can send you the SKP if you wish.
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Thu Mar 26, 2015 11:13 am

Dave R wrote:I tried it on a simple box and face. It worked fine. Tried it on a slightly more complicated model and it splatted, twice. I can send you the SKP if you wish.

Please PM me the SKP[s] that splatted.
I have taken pains to minimize this kind of thing, so I'll be interested to see what's up. :?
I know that very tiny edges can cause issues as they won't intersect with the face to form an 'edge' - but from your modeling I'd expect no such issues ;)
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Thu Mar 26, 2015 11:41 am

I'll send you the SKP when I get home from work. Sorry for the delay.
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby TIG » Mon Mar 30, 2015 4:10 pm

Here's v4.0

Download

I have completely recoded it.
It works with Dave's example SKP [PM'd] and all others that have had issues in the past.
It has so far worked faultlessly.
It is now faster and more robust too...

Feedback please...
1
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby Dave R » Tue Mar 31, 2015 12:57 am

It works! :D

Excellent work, sir. Thank you very much.

Ado Chalkboard shadow.png
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby pilou » Tue Mar 31, 2015 9:51 am

Inspecting mirrors is a thing I could easily see myself doing.
:D
0
Frenchy Pilou
Is beautiful that please without concept!
Speedy Galerie
User avatar
pilou 
Top SketchUcator
 

Re: [Plugin] ShadowProjector

Postby AirWindSolar » Fri Feb 26, 2016 9:11 pm

Still getting fairly consistent crashes on a large and moderately complex (29,500 faces on an area of interest of about 55 acres) model. It seems to get through a few steps, though, as it never crashes until a few minutes in. Is there a log file somewhere that might show what is causing the splat, or at least what stage it's happening at?
0

AirWindSolar 
 

Re: [Plugin] ShadowProjector

Postby TIG » Fri Feb 26, 2016 9:20 pm

I suspect this is just too complex, sorry.

Have you tried splitting it into smaller parts... :?
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ShadowProjector

Postby AirWindSolar » Fri Feb 26, 2016 11:46 pm

I did at one point, and one relatively small section (2-3 buildings, maybe 1/2 acre) still crashed it every time. Will try to reproduce that and post the file to see if there's something squirrelly going on with the geometry in it.
0

AirWindSolar 
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 

PreviousNext


 

Return to Plugins

Who is online

Users browsing this forum: No registered users and 99 guests

Visit our sponsors: