On Wed, Mar 20, 2013 at 9:38 AM, Alex Harui <aha...@adobe.com> wrote:
> > > > On 3/20/13 9:15 AM, "jude" <flexcapaci...@gmail.com> wrote: > > > On Tue, Mar 19, 2013 at 8:08 PM, Om <bigosma...@gmail.com> wrote: > >> > >> > >> Please go on with the rambling :-) Its nice to know that others are > >> thinking about things I am thinking as well - and that I am crazy! > >> > >> BTW, I have a nice little carefully crafted XSLT that converts a basic > FXG > >> node with just the Rect element to SVG. I am planning on tackling the > >> 'fill' element next. Once I have a decently working XSLT that simply > >> converts an FXG skin that can be directly rendered on a browser, I will > >> start posting my work for others to look at at hopefully, contribute. > >> > > > > Cool. :) I was reading a post yesterday about the massive performance > > improvements by rasterizing the vectors and then moving them to the GPU, > > http://goo.gl/WXkmA. I haven't seen this approach before and it may not > > have been possible before but with Stage 3d, Starling and WebGL it now > is a > > choice. And if that works then we may be able to apply it to the Flex SDK > > and even HTML output (it renders at difference sizing so as you zoom in > or > > out it maintains fidelity - I think). > Did I read that post correctly? I think it supports my choice of bitmaps > over vectors for the future. > The way I see it, bitmaps are good for performance for some scenarios. But that does not mean that we have to do away with vectors completely. I dont see a straight line between these two different trains of thoughts. If I want to have a plain blue colored background on an app thats going to run on a retina display, why would I chose to embed a big ass image instead of just drawing a blue colored rectangle (like we do today in the spark/fxg skins) And what happens if I want to change the color dynamically, god forbid if I have to apply a filter or animate a gradient. We do all sorts of such things in our Flex apps today. Vectors are one big advantage that Flash has over straight HTML apps. Now that SVG is being considered more seriously in the HTML5 era, we have a great chance to bring that goodness over. HTML5 apps that fit different various screen dimensions is the holy grail that folks are trying to achieve. Flex has a good chance to help in this area, because that is what it specializes in. Again as I said, both FXG and SVG have very good support for Bitmaps. So there is no need to exclude this option at all. Those who want to use just bitmaps for skinning can still go ahead and do that. > > > > Someone mentioned in the comments on a recent post that if we replaced > > DisplayObject type with IDisplayObject we could use our own renderers. We > > could then have in our Flex applications something like a > > stageRenderer:IRenderer property / interface. > > > > Really, if we get this to work and apps run as silky smooth as games do > > then it will put Flex / AIR on the map for apps. > I have heard that the key to performance is the number of times you need to > render your vectors to bitmaps. There are certain things (like zoom > effects) that you don't think twice about using in vector rendering that > kill you when trying to get to the GPU. I think I was told that if you can > design your visuals as a set of fixed size visuals (which I guess games > often do) then you get the benefits of GPU. Then the question is, if your > visuals are fixed size, why not transcode them to bitmaps at compile time > instead of run time? > My question to you is, how do you know during compile time that the visuals are fixed size? Do you plan to do a static analysis of the code to see if they are not being manipulated for dimensions, filters, gradients, etc.? If it is a compiler switch, then yes, this approach would work. But IMHO that would put an undue restriction on developers. Bitmap spritesheets are great for games because the objects dont change in size generally. But the kind of fluid layout apps Flex devs are used to building, we still need vectors to do most work. Maybe scale-9 skinning would fix some problems, but I am not sure if it will solve everything. I have also been reading some stuff about gpu accelerated SVG. I will do a bit more research before posting links here. Thanks, Om > > -- > Alex Harui > Flex SDK Team > Adobe Systems, Inc. > http://blogs.adobe.com/aharui > >