Image scaling Macro
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
-
- Veteran
- Posts: 2611
- Joined: Tue Feb 21, 2012 8:07 pm
- Location: Torino - Italy
Re: Image scaling Macro
Looks good!
Re: Image scaling Macro
Probably a line should be added to the Description section, something like:renatorivo wrote:here sandbox for Macro Image scaling
http://www.freecadweb.org/wiki/index.ph ... ge_Scaling
"This Macro does not deal with parallax, so distortion will increase from the center towards the edges which will affect the measured distances."
And if adding reference to "parallax" then a link to Wikipedia (https://en.wikipedia.org/wiki/Parallax) is probably advisable as most people will probably recognise what parallax is but not necessarily recognise the word itself.
As parallax is the major problem with this method, perhaps the first sentence should not use the word "easy"? Dealing with parallax where there is any depth of field is certainly not easy. In fact I would suppose that overcoming it would require stereoscopic viewpoints with sufficient distance between them - something that is not easy when the user only has one photographic image.
Re: Image scaling Macro
Maybe focus on the intended use drawings and similar 2D imagespiffpoof wrote:As parallax is the major problem with this method, perhaps the first sentence should not use the word "easy"? Dealing with parallax where there is any depth of field is certainly not easy. In fact I would suppose that overcoming it would require stereoscopic viewpoints with sufficient distance between them - something that is not easy when the user only has one photographic image.
For photos of objects etc you probably want to turn to GIMP or similar for straighten them out first.
Maybe:
Macro for easy scaling of drawings etc. imported with Image workbench.
Re: Image scaling Macro
Yes, that sounds great.JAndersM wrote:Maybe:
Macro for easy scaling of drawings etc. imported with Image workbench.
The reason I mention this is that I suspect that most people reading the word "image" will think of a photographic image (certainly I don't remember anybody referring to a diagram or blueprint as an "image"). But if the description uses words like "diagram" or "2D drawings" (for example) then I think it is very clear.
And maybe there should be a reference to the nefarious role of parallax _IF_ the user decides to use photographic images.
But that's the whole point, once a photograph has significant parallax, neither Gimp nor PhotoShop nor anybody else can disentangle it. It's the same as trying to extract stereo from a recording that has been recorded in monaural. Gimp et al can deal with barrel distortion and lots of other flaws in the photographs but not parallax.JAndersM wrote: For photos of objects etc you probably want to turn to GIMP or similar for straighten them out first.
-
- Veteran
- Posts: 2611
- Joined: Tue Feb 21, 2012 8:07 pm
- Location: Torino - Italy
Re: Image scaling Macro
Editedpiffpoof wrote: JAndersM wrote:
Maybe:
Macro for easy scaling of drawings etc. imported with Image workbench.
Yes, that sounds great.
The reason I mention this is that I suspect that most people reading the word "image" will think of a photographic image (certainly I don't remember anybody referring to a diagram or blueprint as an "image"). But if the description uses words like "diagram" or "2D drawings" (for example) then I think it is very clear.
And maybe there should be a reference to the nefarious role of parallax _IF_ the user decides to use photographic images.
http://www.freecadweb.org/wiki/index.ph ... ge_Scaling
Renato
Re: Image scaling Macro
Fine! To be exact I think piffpoof means the parallax effect viewing objects at different distances if not close (at) the line of sight rather than the parallax due to different lines of sight. This makes scaling hard to do:
You can reuse the image in the wiki if you want. (I drew it)-
- Veteran
- Posts: 2611
- Joined: Tue Feb 21, 2012 8:07 pm
- Location: Torino - Italy
Re: Image scaling Macro
Hi,
thanks for the picture, I will use it
conic or conical perspective?, exact?
Edit
added picture
thanks for the picture, I will use it
conic or conical perspective?, exact?
Edit
added picture
Re: Image scaling Macro
That might be a better description. What do you say piffpoof?renatorivo wrote:conic or conical perspective?, exact?
Re: Image scaling Macro
I've amended the diagram as follows: The problem which I'm trying to warn of is that with the 2 objects I've added. They are at different depths from the user viewpoint and at different angles but their precise placement can not be determined from a photograph without additional information (e.g. stereoscopic viewpoint).JAndersM wrote:That might be a better description. What do you say piffpoof?renatorivo wrote:conic or conical perspective?, exact?
The macro write up looks great.