Image Region

Image Region - ⛔ Extends SMath Studio with an Image Region. - Mensajes

#1 Publicado: 2/5/2013 8:04:34
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Extends SMath Studio with an Image Region.

Mostrar spoiler



ImageRegion_screen0.png MathcadFileAccess_screen1.png
Russia ☭ forever, Viacheslav N. Mezentsev
A 3 usuarios les gustó este mensaje
Andrey Ivashov 2/5/2013 8:18:00, Radovan Omorjan 2/5/2013 8:33:00, Davide Carpi 2/5/2013 18:26:00
#2 Publicado: 2/5/2013 11:31:11
kaka

kaka

1 me gusta en 25 mensajes.

Grupo: User

Wrote

Need to change size manually after recalculation.

Sources: https://smath.info/svn/public/plugins/ImageRegion/

ImageRegion_screen0.png



Like this one. If will be great to load and display the excel file in Smath as well.
#3 Publicado: 2/5/2013 17:10:56
kaka

kaka

1 me gusta en 25 mensajes.

Grupo: User

why I cannot find the dll in the zip file.
#4 Publicado: 2/5/2013 18:03:19
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

Same problem here. The plugin folder in the zip file is empty.
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
#5 Publicado: 2/5/2013 18:06:28
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Oh, sorry, now fixed.
Russia ☭ forever, Viacheslav N. Mezentsev
A 2 usuarios les gustó este mensaje
Davide Carpi 2/5/2013 18:26:00, Martin Kraska 2/5/2013 18:19:00
#6 Publicado: 2/5/2013 18:29:50
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

Plugin works, except for Mathcad file acces, which I have not installed yet. Also, I did not test the image import.

Resizing requires just to touch the handles, then the size jumps to correct value. One has to be careful with image size, using 128x128 for the second image, Smath crashed when I tried to rename the variable image.

Also, there seems to be an indexing problem. For some sizes, the result of the second computation does not overwrite the upper left rectangle as expected but has some shift. Don't know if that is due to the formula or due to the plugin.
imageregion1.PNG
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
A 1 usuarios les gustó este mensaje
#7 Publicado: 2/5/2013 18:36:06
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Yes, it's strange. I'll see what's up. I need more sleep.

P.S. We have to change the names of variables. We use the same variable image.
Russia ☭ forever, Viacheslav N. Mezentsev
A 1 usuarios les gustó este mensaje
Davide Carpi 2/5/2013 18:38:00
#8 Publicado: 4/5/2013 6:57:21
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

I did some more testing in connection with MathcadFileAccess.

The image region produced artefacts with data read by READRGB(). It seems that from a certain point there is a shift in pixel indexing. Graylevels read by READ_IMAGE are displayed correctly, just as images from files.
The problem does not occur with the win logo from your MathcadFileAccess Examples. It, however, persists if I save the fhb logo in different formats, including various tastes of bmp.

Also, the SMath logo as available at the download section in the forum is not displayed correctly. READ_IMAGE fails to read it at all.

P.S. I also noticed that I cannot put a function call to the placeholder but have to assign a matrix in advance.

P.P.S: The gray level image has slightly colored shades in the image which are obvious in high zoom levels. I can't tell if that is a READ_IMAGE problem or an imageregion problem.
imageregion2.PNG
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
A 1 usuarios les gustó este mensaje
#9 Publicado: 4/5/2013 10:36:27
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Updated (MathcadFileAccess_20130504 and ImageRegion_20130504).
mkraska, I found two errors in the functions. Thanks for your examples.

Not all image formats are supported. Some files can't be loaded.

P.S. LitePipe Demo example.

LitePipes_screen0.png
LitePipes_20130504.zip (1,33 MiB) descargado 617 vez(es).
Russia ☭ forever, Viacheslav N. Mezentsev
A 1 usuarios les gustó este mensaje
Martin Kraska 4/5/2013 11:23:00
#10 Publicado: 4/5/2013 11:36:19
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

Wrote


Not all image formats are supported. Some files can't be loaded.



uni, thanks again for bugfixing. What a pity that the SMath logo is one of poor unloadable files...

After updating both MathcadFileAccess and ImageRegion:
- The imageregion example works fine.
- The image examples in the MathcadFileAccess examples dir have no images included.
- There is a hardwired local path from your computer in the writebin example. If changed to currentdir everything works.

My examples, however, do not work.
- The vertical offset of the lower right image triangle has gone
- The colorful artefacts in the graylevel plots have gone
- Now, there is a more obvious horizontal shift in the image

Do i have to assume that my test image is buggy? It is the very expemsive new official logo of our school, taken from the website.

P.S. I did not get to run the mcadefi stuff so far. This trick with putting it beside the smath exe did not work for me.

imageregion3.PNG
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
#11 Publicado: 4/5/2013 11:42:37
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

This is strange, I checked the plugin on your example. Check version:

ImageRegion - 1.0.4872.36288,
MathcadFileAccess - 1.0.4872.36253.

I forgot to say that you need to update both plugins. Errors have been in both plugins simultaneously.
Russia ☭ forever, Viacheslav N. Mezentsev
#12 Publicado: 4/5/2013 12:17:50
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

Wrote

This is strange, I checked the plugin on your example. Check version:

ImageRegion - 1.0.4872.36288,
MathcadFileAccess - 1.0.4872.36253.

I forgot to say that you need to update both plugins. Errors have been in both plugins simultaneously.



You are right, It was my fault. I failed to complete the update by moving the dll...

Now just the smath logo seems to resist the debugging effort.



imageregion4.PNG
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
#13 Publicado: 4/5/2013 12:41:11
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

I compared the results with Mathcad and I think I swapped the colors (I'll read the Mathcad Help).

MathcadFileAccess_screen1.png
Russia ☭ forever, Viacheslav N. Mezentsev
#14 Publicado: 4/5/2013 15:13:00
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Updated. Now colors not swapped. Small improvements.
Russia ☭ forever, Viacheslav N. Mezentsev
#15 Publicado: 12/10/2013 2:26:34
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Updated. Added support for svg.

ImageRegion. SVG. Example 1.png ImageRegion. SVG. Example 2.png
Russia ☭ forever, Viacheslav N. Mezentsev
A 2 usuarios les gustó este mensaje
Martin Kraska 12/10/2013 7:26:00, Davide Carpi 13/10/2013 6:30:00
#16 Publicado: 12/10/2013 7:34:10
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

I cannot display the attached image (had to zip the image because svg is not allowed as attachment file type). The file is generated using TpX and cleanly displays in IE.

Also, after downloading the plugin, further access to the online gallery is denied. This also happens with Davide's Conditionally Formatted Label but not with Andrey's Excel Files Plugin.

Tested with the installer version of 0.96.4909 using plugin version 1.0.5033.22634

No such access problems with the portable version. The display problem is present in both versions.
Moment-2.zip (1,09 KiB) descargado 542 vez(es).
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
#17 Publicado: 12/10/2013 9:51:48
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Updated. Try now.
ImageRegion. SVG. Example 3.png
Russia ☭ forever, Viacheslav N. Mezentsev
A 1 usuarios les gustó este mensaje
Martin Kraska 12/10/2013 10:04:00
#18 Publicado: 12/10/2013 10:08:30
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

Confirmed for installer and portable version, works now. Thanks a lot.

Gallery access issue remains, but might have causes outside the plugin.

PS: how about an optional background? The grid is visible through the image, which is close to paper-and-pencil-feeling, but which might be a matter of taste -> optional setting would be fine.
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
#19 Publicado: 12/10/2013 10:14:56
Вячеслав Мезенцев

Вячеслав Мезенцев

1.558 me gusta en 1.868 mensajes.

Grupo: Moderator

Wrote

PS: how about an optional background? The grid is visible through the image, which is close to paper-and-pencil-feeling, but which might be a matter of taste -> optional setting would be fine.


Ok, I'll do it later.
Russia ☭ forever, Viacheslav N. Mezentsev
#20 Publicado: 12/10/2013 10:27:38
Martin Kraska

Martin Kraska

1.361 me gusta en 2.275 mensajes.

Grupo: Moderator

Wrote

Wrote

PS: how about an optional background? The grid is visible through the image, which is close to paper-and-pencil-feeling, but which might be a matter of taste -> optional setting would be fine.


Ok, I'll do it later.


Looking forward to the implementation.

Still there is another, more important issue: could you please interpret relative paths with respect to the directory of the current SMath document instead of the current directory? This would create portable documents and enable putting examples in the activebook help system.
Technische Mechanik mit SMath Studio: https://link.springer.com/book/10.1007/978-3-658-50592-9
  • Nuevos mensajes
  • Sin mensajes nuevos