Re: [Bf-committers] Icon scaling
Hi, On 08.11.2011 04:08, Campbell Barton wrote: Firstly I think the main issue with getting this into blender is finding someone with the time who wants to work on this. I was kind of offering to do it, but I would have to experiment with my rendering code, to implement the shape hinting in the first place. Or else it provides no benefit to scaled down bitmaps. I have no idea if I even have the time, but it's one of the things I would love to work on, and I just wanted to gauge interest after seeing that Blender could benefit from this. Regarding implementation - Even if the icons render fast, we would still need to pass them to OpenGL, while probably not _really_ slow doing this every draw, its a step backward from using a textures which are fast. I'd expect we would end up doing something similar to fonts where the vector data generates a texture at different sizes. Yes, the generated bitmaps would have to end up in some cache, or it would be too expensive. One may even want to put them into a persistent cache so it doesn't slow down program startup each time. That being said, the rendering is really extremely fast. In Haiku, we do have an icon cache based on the resulting bitmaps in the file manager, but the first time icons are needed, they are loaded from disk as vector icons, parsed from the format into the shape data model and then rendered. It seems that the reduced disk size compared to PNGs or other formats, and thus faster loading time compensates the additional rendering time. At least I was careful not to introduce a perceptable delay when working on this stuff. However at this point we can probably just get away with using larger icons - 32x32 for eg - and it will be `good enough`, That may indeed be the case. Something else to consider when updating the icon system is to allow addons to use their own icons. To understand what problem you are referring to, I would have to become familar with the codebase. :-) btw - With SDL1.3 you should be able to run blender, though I'm not sure how far along the SDL1.3 port is. I was helping to mentor the GSoC project to port SDL 1.3 to Haiku, reviewing the patches and providing a lot of input. It's another item on my TODO list to help improve this more, but I am pretty sure our OpenGL implementation needs more work in general, SDL is just another client of that API and whether or not it is used directly or indirectly, it needs to improve. :-) Thank you for your feedback! Best regards, -Stephan ___ Bf-committers mailing list Bf-committers@blender.org http://lists.blender.org/mailman/listinfo/bf-committers
Re: [Bf-committers] Icon scaling
Hi Stephan, generally this would be nice to have and look much crisper of course. Firstly I think the main issue with getting this into blender is finding someone with the time who wants to work on this. Regarding implementation - Even if the icons render fast, we would still need to pass them to OpenGL, while probably not _really_ slow doing this every draw, its a step backward from using a textures which are fast. I'd expect we would end up doing something similar to fonts where the vector data generates a texture at different sizes. However at this point we can probably just get away with using larger icons - 32x32 for eg - and it will be `good enough`, Something else to consider when updating the icon system is to allow addons to use their own icons. btw - With SDL1.3 you should be able to run blender, though I'm not sure how far along the SDL1.3 port is. - Campbell On Sun, Nov 6, 2011 at 8:53 PM, Stephan Aßmus supersti...@gmx.de wrote: Hi all, this is my first post to the list. My name is Stephan Aßmus and I am a contributor to the Haiku project, www.haiku-os.org. I stumbled over a tutorial about using Cycles and this has renewed my interest in Blender. Blender is pretty powerful, but I think it is still not approachable without doing Internet searches and following Tutorials (for example I had to look up how to close views, or stumbled across Shift-A in a video tutorial after wondering how I even create new objects). However, awesome features such as Cycles makes potential users more willing to take these steps, such as in my case. :-) One thing I really like about the interface, is that it is scalable by providing a device DPI value in the preferences. The only problem with this approach is that icons are scaled up and look blurry. Maybe a solution would be to store all icons in a bigger resolution, but it won't be perfect. For the Haiku project, I have developed a scalable vector icon format which takes extremely little disk space to store, and is very fast to render without artifacts, since it is using single pass compound shape rendering based on Anti-Grain Geometry. Some of you may be familiar with this awesome 2D graphics framework. I have tried to search for previous discussion on this subject in the Blender world, but nothing has shown up. Maybe I didn't look in the right places. My icon rendering as such would not solve the blurriness as is. But it has the potential to achieve this. Just as text rendering uses glyph hinting to align the shapes of glyphs to device pixels, a similar technique could be used for rendering scaled vector icons. But it should be difficult to do it with a general purpose vector format such as SVG, versus a dedicated icon format in which meta information can be given to shapes. For example, my icon format already contains a mechanism for making shapes disappear or appear in certain ranges of global scale. The format and renderer could be extended to support tagging shapes for being pixel aligned at render time. One post I stumbled across suggest that the original format of the Blender icons is SVG. The one editor which exists for creating icons in my format does support SVG import (and export), but the import is quite limited. One drawback of the idea is that all icons would have to be worked over to make use of all the features of my format (sharing of paths and styles) to benefit from the possible small disk size. And my icon editor only exists for Haiku at the moment. :-) But is there even some general interest in this idea? To learn more about the format, I just found out there is even a Wikipedia page (while looking up my articles): http://en.wikipedia.org/wiki/Haiku_Vector_Icon_Format Best regards, -Stephan ___ Bf-committers mailing list Bf-committers@blender.org http://lists.blender.org/mailman/listinfo/bf-committers
Re: [Bf-committers] Icon scaling
Your idea about hinting for icon rendering is exactly the same as one I had last year when working on am icon set for a medical company last year! Perhaps it's outside the scope of blender to create such a system, but I certainly believe there is potential for the idea. I was thinking about trying to implement it in inkscape later this year, but had forgotten about it. This gives some new interest for sure ;) Luke On 11/6/11, Stephan Aßmus supersti...@gmx.de wrote: Hi all, this is my first post to the list. My name is Stephan Aßmus and I am a contributor to the Haiku project, www.haiku-os.org. I stumbled over a tutorial about using Cycles and this has renewed my interest in Blender. Blender is pretty powerful, but I think it is still not approachable without doing Internet searches and following Tutorials (for example I had to look up how to close views, or stumbled across Shift-A in a video tutorial after wondering how I even create new objects). However, awesome features such as Cycles makes potential users more willing to take these steps, such as in my case. :-) One thing I really like about the interface, is that it is scalable by providing a device DPI value in the preferences. The only problem with this approach is that icons are scaled up and look blurry. Maybe a solution would be to store all icons in a bigger resolution, but it won't be perfect. For the Haiku project, I have developed a scalable vector icon format which takes extremely little disk space to store, and is very fast to render without artifacts, since it is using single pass compound shape rendering based on Anti-Grain Geometry. Some of you may be familiar with this awesome 2D graphics framework. I have tried to search for previous discussion on this subject in the Blender world, but nothing has shown up. Maybe I didn't look in the right places. My icon rendering as such would not solve the blurriness as is. But it has the potential to achieve this. Just as text rendering uses glyph hinting to align the shapes of glyphs to device pixels, a similar technique could be used for rendering scaled vector icons. But it should be difficult to do it with a general purpose vector format such as SVG, versus a dedicated icon format in which meta information can be given to shapes. For example, my icon format already contains a mechanism for making shapes disappear or appear in certain ranges of global scale. The format and renderer could be extended to support tagging shapes for being pixel aligned at render time. One post I stumbled across suggest that the original format of the Blender icons is SVG. The one editor which exists for creating icons in my format does support SVG import (and export), but the import is quite limited. One drawback of the idea is that all icons would have to be worked over to make use of all the features of my format (sharing of paths and styles) to benefit from the possible small disk size. And my icon editor only exists for Haiku at the moment. :-) But is there even some general interest in this idea? To learn more about the format, I just found out there is even a Wikipedia page (while looking up my articles): http://en.wikipedia.org/wiki/Haiku_Vector_Icon_Format Best regards, -Stephan ___ Bf-committers mailing list Bf-committers@blender.org http://lists.blender.org/mailman/listinfo/bf-committers -- Sent from my mobile device From Luke ___ Bf-committers mailing list Bf-committers@blender.org http://lists.blender.org/mailman/listinfo/bf-committers
[Bf-committers] Icon scaling
Hi all, this is my first post to the list. My name is Stephan Aßmus and I am a contributor to the Haiku project, www.haiku-os.org. I stumbled over a tutorial about using Cycles and this has renewed my interest in Blender. Blender is pretty powerful, but I think it is still not approachable without doing Internet searches and following Tutorials (for example I had to look up how to close views, or stumbled across Shift-A in a video tutorial after wondering how I even create new objects). However, awesome features such as Cycles makes potential users more willing to take these steps, such as in my case. :-) One thing I really like about the interface, is that it is scalable by providing a device DPI value in the preferences. The only problem with this approach is that icons are scaled up and look blurry. Maybe a solution would be to store all icons in a bigger resolution, but it won't be perfect. For the Haiku project, I have developed a scalable vector icon format which takes extremely little disk space to store, and is very fast to render without artifacts, since it is using single pass compound shape rendering based on Anti-Grain Geometry. Some of you may be familiar with this awesome 2D graphics framework. I have tried to search for previous discussion on this subject in the Blender world, but nothing has shown up. Maybe I didn't look in the right places. My icon rendering as such would not solve the blurriness as is. But it has the potential to achieve this. Just as text rendering uses glyph hinting to align the shapes of glyphs to device pixels, a similar technique could be used for rendering scaled vector icons. But it should be difficult to do it with a general purpose vector format such as SVG, versus a dedicated icon format in which meta information can be given to shapes. For example, my icon format already contains a mechanism for making shapes disappear or appear in certain ranges of global scale. The format and renderer could be extended to support tagging shapes for being pixel aligned at render time. One post I stumbled across suggest that the original format of the Blender icons is SVG. The one editor which exists for creating icons in my format does support SVG import (and export), but the import is quite limited. One drawback of the idea is that all icons would have to be worked over to make use of all the features of my format (sharing of paths and styles) to benefit from the possible small disk size. And my icon editor only exists for Haiku at the moment. :-) But is there even some general interest in this idea? To learn more about the format, I just found out there is even a Wikipedia page (while looking up my articles): http://en.wikipedia.org/wiki/Haiku_Vector_Icon_Format Best regards, -Stephan ___ Bf-committers mailing list Bf-committers@blender.org http://lists.blender.org/mailman/listinfo/bf-committers