[Plugin] ImageTrimmer

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Thu Mar 28, 2013 8:47 pm

TIG wrote:The only difference I have is the last item Java Quick Starter is unchecked in my version, BUT I'd not expect that to be an issue...

Can you run Sketchup as an Admin and see if it helps...


Nothing new.... same old story :(

I tried once again and got just basic file in TrimmedImages folder.

Then, as you can see, I tried with input in RC, but TrimmedImages folder stay unchanged still only basic image.

RC3.png
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby picky1958 » Thu Mar 28, 2013 8:53 pm

eLaCiD wrote:
TIG wrote:The only difference I have is the last item Java Quick Starter is unchecked in my version, BUT I'd not expect that to be an issue...

Can you run Sketchup as an Admin and see if it helps...


Nothing new.... same old story :(

I tried once again and got just basic file in TrimmedImages folder.

Then, as you can see, I tried with input in RC, but TrimmedImages folder stay unchanged still only basic image.

RC3.png


I had exactly the same problems. I never got it to work either :(
0
User avatar
picky1958 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby Dave R » Thu Mar 28, 2013 8:57 pm

Works fine for me on two PCs and my Mac.
0
Etaoin Shrdlu


%

(THERE'S NO PLACE LIKE)

G28 X0.0 Y0.0 Z0.0

M30

%
User avatar
Dave R 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Thu Mar 28, 2013 8:59 pm

picky1958 wrote:
eLaCiD wrote:
TIG wrote:The only difference I have is the last item Java Quick Starter is unchecked in my version, BUT I'd not expect that to be an issue...

Can you run Sketchup as an Admin and see if it helps...


Nothing new.... same old story :(

I tried once again and got just basic file in TrimmedImages folder.

Then, as you can see, I tried with input in RC, but TrimmedImages folder stay unchanged still only basic image.

RC3.png


I had exactly the same problems. I never got it to work either :(



But somewhere there must be a Catch. I hope so :)
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Thu Mar 28, 2013 9:02 pm

Dave R wrote:Works fine for me on two PCs and my Mac.


Yes, but the problem is not noticeable when running than when not working :)
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby picky1958 » Thu Mar 28, 2013 9:03 pm

eLaCiD wrote:
picky1958 wrote:
eLaCiD wrote:
TIG wrote:The only difference I have is the last item Java Quick Starter is unchecked in my version, BUT I'd not expect that to be an issue...

Can you run Sketchup as an Admin and see if it helps...


Nothing new.... same old story :(

I tried once again and got just basic file in TrimmedImages folder.

Then, as you can see, I tried with input in RC, but TrimmedImages folder stay unchanged still only basic image.

RC3.png


I had exactly the same problems. I never got it to work either :(



But somewhere there must be a Catch. I hope so :)



I gave up on it. I am good with computers but when it comes up to some terms, there is also a language barrier. Some things are hard to find when you get instructions in english and you are hanging around with a PC that only speaks german! ;)
0
User avatar
picky1958 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Thu Mar 28, 2013 9:46 pm

picky1958 wrote:
I gave up on it. I am good with computers but when it comes up to some terms, there is also a language barrier. Some things are hard to find when you get instructions in english and you are hanging around with a PC that only speaks german! ;)


Yes it is a problem. Most people I know have Windows upgrade on its own local language.
My knowledge of English is poor, but there's no way for me to upgrade Windows on my PC to local language just for the reason you mention. :)

As someone said, Hope dies last.
To give up is not an option :)
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Fri Mar 29, 2013 2:04 pm

I've been thinking a bit about this problem and the conclusion is as follows

When I start Image trimer from SU as I can see in status line

StatusLine.png


there appears one by one dot indicating that Image Trimer works.
In folder TrimmedImage shows up a copy of basic image.
Contents of files from.ini and to.ini are created with rigt paths what all indicates this part work fine.

But after this point, after minute or minute and a half it stops.
In folder TrimmedImage there is no files image[Edges].dat and image[Edges].png

The main question is, what heppens in that minute, according status line ImageTrimer works something.
Does it produce this two files image[Edges].dat and image[Edges].png or not.
We have two options
1.)
Files are produced but sometning has gone wrong and files can not be saved in TrimmerdImage folder
2)
Files are not produced which brings us back to the question of what then happens in that minute, minute and half.

On the other side when EdgeDetector.jar is triggered manualy it produce this two files in folder.
When EdgeDetector.jar is trigered inside RC nothing happens.
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Fri Mar 29, 2013 2:43 pm

If you try this in the RC
UI.openURL("file:///"+"../full/path/to/EdgeDetector.jar")
what happens ?
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Fri Mar 29, 2013 4:19 pm

TIG wrote:If you try this in the RC
UI.openURL("file:///"+"../full/path/to/EdgeDetector.jar")
what happens ?


Full path to EdgeDetector.jar is :
C:/Program Files/Google/Google SketchUp 8/Plugins/SKMtools/EdgeDetector.jar

In this case if this is correct

RC4.png


after enter and few seconds I got just this

RC5.png


and nothing more
Folder TrimmedImage is unchanged.
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Fri Mar 29, 2013 4:28 pm

Has it then made the other files in the 'Trimmed' folder ?
If so we know it's both runnable and working...
Is there a .dat file?
This tells Ruby where to draw the edges that are the image's 'perimeter' ?
Can you PM a zip of the Trimmed folder including any .dat file to me ?
So why isn't it then reading the .dat file? :?
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Fri Mar 29, 2013 5:28 pm

TIG wrote:Has it then made the other files in the 'Trimmed' folder ?
If so we know it's both runnable and working...
Is there a .dat file?
This tells Ruby where to draw the edges that are the image's 'perimeter' ?
Can you PM a zip of the Trimmed folder including any .dat file to me ?
So why isn't it then reading the .dat file? :?


Well, we have three situations..

1.)
When I start ImageTrimer from SU then
in files from.ini and to.ini appears correct path
in folder TrimmedImages appears copy od image.png
And nothing more.

2.)
When I start manualy by click EdgeDetector.jar
with the condition - there is corect path in files from.ini and to.ini
and condtition - there is image.png in TrimmedImages folder

In folder TrimmedImages next to image.png appears image[Edges].dat and image[Edges].png

3.)
When I start EdgeDetector.jar inside RC nothing happens.
Files image[Edges].dat and image[Edges].png doesn't appear in b] TrimmedImages [/b] folder

Zip of TrimmedImage folder is sent over PM
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Fri Mar 29, 2013 6:23 pm

A .jar file won't execute through the RC unless you use UI.openURL("file:///"+full_path_to_jar), which we know works... I think - please retry and confirm this if there's any doubt...

The edges dat file that is necessary is made in the set you PM'd, and it is fine - here's a zoomed out view of the 'text' - you can clearly see the 0/1 pattern matching the image outline !

So why isn't it working through the main ruby code ?

The .jar isn't 'executing' in the code...
So there must be something wrong with either your permissions - are you an admin ?
OR perhaps the Java settings are not right for some reason???
Do you AND ALL others have FULL access to the TrimmedImages folder ?
Perhaps you do but others like Java/Sketchup don't ???
Is there FULL rights for ALL to the SKMtools folder/files and subfolders ???
It's as if something is stopping the one step needed with the jar file 'opening' and making the dat file...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Fri Mar 29, 2013 7:12 pm

TIG wrote:A .jar file won't execute through the RC unless you use UI.openURL("file:///"+full_path_to_jar), which we know works... I think - please retry and confirm this if there's any doubt...

The edges dat file that is necessary is made in the set you PM'd, and it is fine - here's a zoomed out view of the 'text' - you can clearly see the 0/1 pattern matching the image outline !

So why isn't it working through the main ruby code ?

The .jar isn't 'executing' in the code...
So there must be something wrong with either your permissions - are you an admin ?
OR perhaps the Java settings are not right for some reason???
Do you AND ALL others have FULL access to the TrimmedImages folder ?
Perhaps you do but others like Java/Sketchup don't ???
Is there FULL rights for ALL to the SKMtools folder/files and subfolders ???
It's as if something is stopping the one step needed with the jar file 'opening' and making the dat file...



On this computer is only one user acount - my, with description computer administrator.

Full Java sattings I posted here before.

All folder with subfolder and files in that folders have full rights for ALL

The catch is somewhere here :
EdgeDetector.jar works if is started manualy by click
EdgeDetector.jar doesn't work from RC

When it would be?
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Fri Mar 29, 2013 7:51 pm

If you right-click a jar file and use 'open with...' what does it say ?
Try execute with Java ?
The one difference in the Java Advanced settings between me/you - mentioned earlier - can you try the alternative 'off'...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Fri Mar 29, 2013 8:02 pm

TIG wrote:If you right-click a jar file and use 'open with...' what does it say ?
Try execute with Java ?
The one difference in the Java Advanced settings between me/you - mentioned earlier - can you try the alternative 'off'...


I got this

JavaOpenWith.png
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Sat Mar 30, 2013 12:08 pm

Conclusion - Chapter 2

After many attempts, I came up with something that could lead to a solution.
As I am not friendly with Ruby I tried the following

First. I saw that when I run ImageTrimmer from SU in TrimmedImages folder only get copy of bacic image - someimage.png

Then I saw if I directly run EdgeDetector.jar in TrimmedImages folder I get two files someimage[Edges].dat and someimage[Edges].png

Next I saw when I run ImageTrimmer from SU at start all existing files in TrimmedImages folder are deleted.


Well then I do next :

I start directly EdgeDetector.jar and I get necessery files someimage[Edges].dat and someimage[Edges].png and I copy them out from TrimmedImages folder.

Then I start ImageTrimmer from SU (of course ImageTrimer at start delete this two files from TrimmedImages folder but I have copy of them)

When ImageTrimmer are working I copy back someimage[Edges].dat and someimage[Edges].png in TrimmedImages folder


And on this way plugin works. :thumb:

As I said before Hope dies last and surrender is not an option. :)

TIG, now is your turn :ecstatic:



My grandad who died many years ago and never seen computor know to say something that might be in translation :
You dont have to know everything, but you need to know how to handle :)
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Sat Mar 30, 2013 12:35 pm

Another thought...

Please check your permissions for the SKMtools folder/contents are FULL for EVERYONE...

If you right-click a jar file and use 'Open with...' and choose 'Set default program...'
Try to re-force it to execute with Java, by re-choosing the Java .exe and checking the box 'Always open with this...'

Also recheck each of the Java Control Panel settings match these, which work for me:
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Sat Mar 30, 2013 2:48 pm

TIG wrote:Another thought...

Please check your permissions for the SKMtools folder/contents are FULL for EVERYONE...

If you right-click a jar file and use 'Open with...' and choose 'Set default program...'
Try to re-force it to execute with Java, by re-choosing the Java .exe and checking the box 'Always open with this...'

Also recheck each of the Java Control Panel settings match these, which work for me:


I did like you said.

SKMtools folder/contents are FULL for EVERYONE (it was before)

Java 'Open with' - re-choosing the Java .exe - 'Always open with this...'
It was done.

Java settings is like you post here except I can't mark Mozilla family box then only IE box.
If I mark MF box after click on OK and re-open it shosw again only IE box marked.


But unfortunately it did not bring anything new.
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Sat Mar 30, 2013 3:11 pm

I can't see how to do anything more :?
At least you have a work around...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby eLaCiD » Sat Mar 30, 2013 3:39 pm

TIG wrote:I can't see how to do anything more :?
At least you have a work around...


Maybe you can't maybe you can :)
I am not friendly with Ruby but as I can see with this type of error "No such file or directory" I am not alone.
It seems on some PC configuration for some reason proces is not able to save image[Edges].dat and image[Edges].png in TrimmedImages folder.

There is possibility of syntax in code perhaps?
In this moment I can't see other reason.

Anyway thank you for your time :)
0
User avatar
eLaCiD 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby camaxide » Fri May 31, 2013 7:55 pm

I have used many images successfully but this one seem to crash as soon as it jumps to the part where it should trace the outlines, however - it makes an image in the folder before it crashes. it crashes the entire sketchup.




Any ideas?

On a sidenote - many of the images I had would not trim on my work computer using the newest sketchup - but my home computer with the last google version of sketchup seem to run most fine - except this one.
0

camaxide 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Sat Jun 01, 2013 10:17 am

It might just be too complex an outline...
It is a large file, have you tried reducing its resolution ?
You can make the image say 1600mm high as you pace it...
I tried it at 800px high and it ImageTrimmed fine...
I can't see much difference in the image/texture quality...
If you don't want to reduce the resolution try splitting the image into two separate girls.
You can always recombine the cutouts' geometry into one component later...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby camaxide » Sat Jun 01, 2013 11:27 pm

thanks a lot, very useful reply - I only tried to open, and resave the file making sure it had no sub-transparent pixels.. but I didnt try changing res. Thanks a lot :)
0

camaxide 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby deaneau » Sun Aug 11, 2013 8:30 am

Hi TIG

i have the problem with image trimmer

the ruby console show this

the same error messages in 8pro


whats wrong?

thanks dean
Error: #<Errno::ENOENT: No such file or directory - C:\Users\d\Documents\TrimmedImages\Grenzer_hockt-front_mit_Telefon_klein___[Edges].dat>
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:238:in `readlines'
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:238:in `make_edges'
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:187:in `process_image'
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:164:in `initialize'
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:769:in `new'
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:769
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:238:in `call'
C:/Program Files (x86)/SketchUp/SketchUp 2013/Plugins/SKMtools/ImageTrimmer.rb:238
0
MADE, BORN AND LIVING IN BERLIN
Big Thank You to all Programmers
Some German words are so long that they have a perspective. M.Twain
User avatar
deaneau 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Sun Aug 11, 2013 9:55 am

@deaneau

Check you have full read/write security permissions to your Plugins folder and the contents... Temporary files are written into the SKMtools subfolder etc...

I suspect that the error is occurring because you have non-ascii characters in the name of something - the Image or the SKP itself ?

Are you DE ?
Do not use accented letters in file/folder names.
Ruby can fail to find files etc if you do - it's a known limitation of SketchUp's Ruby n PCs...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby deaneau » Sun Aug 11, 2013 3:55 pm

Hello TIG

nothing is happend.

all file i write without accents.

i have try to remove the write protection at first was ok, however when i open this dialog again the writeprotection is ON again.

the same problem i have with sketchup make
0
MADE, BORN AND LIVING IN BERLIN
Big Thank You to all Programmers
Some German words are so long that they have a perspective. M.Twain
User avatar
deaneau 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Sun Aug 11, 2013 4:17 pm

You'll need admin rights...
Control Panel > Users - make yourself and admin.

You MUST have FULL rights to the Plugins folder to do thing with this tool, AND many other tools for that matter ! ...

Select the Plugins folder's icon
Right-click
Context-menu
Properties
Security
Edit
...
Set each user/group that is listed to have FULL, read/write permissions.
Apply & OK to save...

The changes ought to filter down to all enclosed files and subfolders automatically - but please check the permissions on the tools folder etc...

Next...
Select the Plugins folder's icon
Right-click
Context-menu
Properties
Compatibility
Tick the 'Always run this application as an administrator' box
Apply & OK to save...

Restart SketchUp and retry the tool to see if it now works...
0
TIG
User avatar
TIG 
Global Moderator
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby deaneau » Sun Aug 11, 2013 7:32 pm

done everything , nothing works
0
MADE, BORN AND LIVING IN BERLIN
Big Thank You to all Programmers
Some German words are so long that they have a perspective. M.Twain
User avatar
deaneau 
 

Re: [Plugin] ImageTrimmer v2.2 20110213

Postby TIG » Sun Aug 11, 2013 10:41 pm

Not very useful information.

What happens?
What is created?
Are there error messages in the Ruby Console.
What us the exact name of the SKP, the Image and the containing folder of the SKP ?
Do you have full permission to this containing folder AND to the ../Plugins/SKMtools subfolder [and all of its contents] ??

Please post all of this...
I still feel it's either a permissions issue and/or a filepath naming problem...
0
TIG
User avatar
TIG 
Global Moderator
 

SketchUcation One-Liner Adverts

by Ad Machine » 5 minutes ago



Ad Machine 
Robot
 

PreviousNext


 

Return to Plugins

Who is online

Users browsing this forum: behnood_tk, clockworkwatermelon, Ruslan085 and 16 guests

Visit our sponsors: