[Feature Request] Image plane display properties/save custom material

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
xoomerq
Posts: 3
Joined: Mon May 03, 2021 11:31 pm

[Feature Request] Image plane display properties/save custom material

Postby xoomerq » Tue May 04, 2021 1:54 pm

Hi Folks!
I am new to this forum, I was following the development of FreeCAD for a year or two. Now (...and in future) I want to contribute! :)
This is a (probably) a small feature request, here is the problem and my "workaround":
Importing an Image (for example for tracing) results in opaque image plane, looking from the rear it is almost black (see image below)
image_plane_rear_view.png
image_plane_rear_view.png (174.27 KiB) Viewed 274 times



I figured out, one can customize the Material properties (three dot button) and set them all to white and shininess to zero percent.
image_plane_properties.png
image_plane_properties.png (214.52 KiB) Viewed 274 times



Now the image is visible from the rear (helps a lot, if one is sketching from that view).
image_plane_set_colour.png
image_plane_set_colour.png (203.64 KiB) Viewed 274 times



Slight transparency may improve usability (this one is maybe too trasparent):
image_plane_transparency.png
image_plane_transparency.png (185.38 KiB) Viewed 274 times



My suggestion: Set the material (colour and transparency) properties for the image planes on creating/importing the image. If this is too difficult, maybe create the "plain white material" to select from the drop-down-list.
Also, a nice addition would be to save the user defined materials to the list.

Looking forward to your comments!

https://tracker.freecadweb.org/view.php?id=4653
Syres
Posts: 1008
Joined: Thu Aug 09, 2018 11:14 am

Re: [Feature Request] Image plane display properties/save custom material

Postby Syres » Wed May 05, 2021 10:02 am

Something for you to try as you don't have to recompile FreeCAD. With FreeCAD closed, find the _CommandImageScaling.py file in your build area src\Mod\Image\ImageTools and rename it so you can put it back if needed. Download the attached version below and save it to the same folder. I felt personally that I would only want to make an image viewable from both sides if I was accurately scaling it, some images I just use as a reference shape guide hence the new checkbox in the dialog.

Tested using:

OS: Windows 7 Version 6.1 (Build 7601: SP 1)
Word size of FreeCAD: 64-bit
Version: 0.20.24787 (Git)
Build type: Release
Branch: master
Hash: ea96f1860164ff8a6751b21b3fb4d425fc87f5e5
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.0
Locale: English/United Kingdom (en_GB)
Attachments
_CommandImageScaling.py
(10.66 KiB) Downloaded 3 times
xoomerq
Posts: 3
Joined: Mon May 03, 2021 11:31 pm

Re: [Feature Request] Image plane display properties/save custom material

Postby xoomerq » Wed May 05, 2021 11:22 am

Thank you, it worked like a charm!

Don't you think, this should be the default setting? Is there an advantage that speaks for the black backside, that I do not see 8-) ?
From my experience, other CAD-Software behaves like this. It saves a lot of hazzle for correct orientation. For example: if I want to create a model in positive coordinates, but the picture is only visible from the "negative side". Before my discovery I would have to mirror the picture in an Image Processor and import it again in FreeCAD.
Syres
Posts: 1008
Joined: Thu Aug 09, 2018 11:14 am

Re: [Feature Request] Image plane display properties/save custom material

Postby Syres » Wed May 05, 2021 1:46 pm

xoomerq wrote:
Wed May 05, 2021 11:22 am
Don't you think, this should be the default setting?
All I can say in the four years I've used FreeCAD, I've survived without the facility and I've not heard of anyone else requesting it but that doesn't mean it hasn't been. It'll need someone with C++ knowledge better than mine to make the changes to ImagePane creation code in order for that to work.
UR_
Posts: 1294
Joined: Tue Jan 03, 2017 8:42 pm

Re: [Feature Request] Image plane display properties/save custom material

Postby UR_ » Wed May 05, 2021 2:45 pm

I've set Edit->Preferences->Display->3DView to:

Screenshot 001.png
Screenshot 001.png (2.07 KiB) Viewed 153 times

and result looks like this:

Animation5.gif
Animation5.gif (851.96 KiB) Viewed 153 times

version:
OS: Windows 10 (10.0)
Word size of FreeCAD: 64-bit
Version: 0.20.24825 (Git)
Build type: Release
Branch: master
Hash: ccc4151b3020969450325466e385850783795325
Python version: 3.9.2
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.5.1
Locale: German/Germany (de_DE)
xoomerq
Posts: 3
Joined: Mon May 03, 2021 11:31 pm

Re: [Feature Request] Image plane display properties/save custom material

Postby xoomerq » Wed May 05, 2021 4:08 pm

UR_ wrote:
Wed May 05, 2021 2:45 pm
I've set Edit->Preferences->Display->3DView
That is even better, did not think of that! Thank you, issue resolved :D

How can I close the ticket?
chrisb
Posts: 34269
Joined: Tue Mar 17, 2015 9:14 am

Re: [Feature Request] Image plane display properties/save custom material

Postby chrisb » Wed May 05, 2021 10:53 pm

I have closed the ticket.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.