FreeCAD Website Design

A forum for research and development of the user interface of FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
chrisb
Veteran
Posts: 54309
Joined: Tue Mar 17, 2015 9:14 am

Re: FreeCAD Website Design

Post by chrisb »

It looks very good, but it increases the size by a factor of almost 10. We could have taken the original files from ppemawm then.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Jee-Bee
Veteran
Posts: 2566
Joined: Tue Jun 16, 2015 10:32 am
Location: Netherlands

Re: FreeCAD Website Design

Post by Jee-Bee »

Of course i don't make it better... it is imposible to add information ;)
AR795
Posts: 180
Joined: Fri May 25, 2018 11:55 pm

Re: FreeCAD Website Design

Post by AR795 »

I guess the software did not compress the image. I opened it in Gimp and exported it using the default .jpg format, the size reduced to around 400Kb. Even then the size is quite a lot especially if all images are considered together and this will slow the website. The original files from ppemawm would be the best solution. Still it's cool what A.I. based software can do now-a-days, especially with image editing.
Jee-Bee
Veteran
Posts: 2566
Joined: Tue Jun 16, 2015 10:32 am
Location: Netherlands

Re: FreeCAD Website Design

Post by Jee-Bee »

resizing not that complicated... https://en.wikipedia.org/wiki/Image_scaling
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: FreeCAD Website Design

Post by PrzemoF »

AR795 wrote: Wed Oct 17, 2018 6:33 am I came across this software called A.I. Gigapixel which does super-sampling of images, essentially converting a lower resolution image to a higher resolution one. I gave it a try on one of the images in the website to see how well it performs. Here is the image before super-sampling:


screenshot-01.jpg


And here is after super-sampling:


screenshot-01_output2.jpg


The results are not perfect; in some areas details are lost or skewed but overall it does make the image sharper. So would it be fine to update the images using this technique or are existing images satisfactory?
It's way better!!! Can we use this one on the front page? The engine model is beautiful, but the quality of the image spoils the impression.
AR795
Posts: 180
Joined: Fri May 25, 2018 11:55 pm

Re: FreeCAD Website Design

Post by AR795 »

I think the images can be upscaled without affecting size too much. I did a small test, where I converted all svg files to optimized svg, doubled the resolution of screenshots on the front page (except for the gear image) and used tinypng.com to optimize the file size of all images. So the total size of the images only increased by about ~150Kb altogether. I uploaded the changes on Github to see: https://ar795.github.io/FreeCAD-Homepage/
User avatar
PrzemoF
Veteran
Posts: 3520
Joined: Fri Jul 25, 2014 4:52 pm
Contact:

Re: FreeCAD Website Design

Post by PrzemoF »

AR795 wrote: Wed Oct 17, 2018 8:19 pm I think the images can be upscaled without affecting size too much. I did a small test, where I converted all svg files to optimized svg, doubled the resolution of screenshots on the front page (except for the gear image) and used tinypng.com to optimize the file size of all images. So the total size of the images only increased by about ~150Kb altogether. I uploaded the changes on Github to see: https://ar795.github.io/FreeCAD-Homepage/
In my opinion this is great! I no longer have impression that there is something wrong with my eyes or the monitor :D
User avatar
kkremitzki
Veteran
Posts: 2518
Joined: Thu Mar 03, 2016 9:52 pm
Location: Illinois

Re: FreeCAD Website Design

Post by kkremitzki »

I think replacing the image is a great idea, I'm ready to do it whenever it's ready to be uploaded.
Like my FreeCAD work? I'd appreciate any level of support via Patreon, Liberapay, or PayPal! Read more about what I do at my blog.
AR795
Posts: 180
Joined: Fri May 25, 2018 11:55 pm

Re: FreeCAD Website Design

Post by AR795 »

PrzemoF wrote: Wed Oct 17, 2018 8:22 pm In my opinion this is great! I no longer have impression that there is something wrong with my eyes or the monitor :D
Yeah it makes quite a difference :D
kkremitzki wrote: Wed Oct 17, 2018 8:41 pm I think replacing the image is a great idea, I'm ready to do it whenever it's ready to be uploaded.
Should I upload the images here or create a pull request?
And a small question - In PHP, how do I add a ' character in a string? For example in:

Code: Select all

<?php echo _('See what's new'); ?>
's gives me incorrect syntax highlighting, should I add a \ before the '
Last edited by AR795 on Thu Oct 18, 2018 6:21 am, edited 1 time in total.
chrisb
Veteran
Posts: 54309
Joined: Tue Mar 17, 2015 9:14 am

Re: FreeCAD Website Design

Post by chrisb »

AR795 wrote: Thu Oct 18, 2018 6:12 am

Code: Select all

<?php echo _('See what's new'); ?>
gives me incorrect syntax highlighting, should I add a \ before the '
You can quote it or use double quotes - php can handle both:

Code: Select all

<?php echo _("See what's new"); ?>
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Post Reply