6 ms·
Exactly what I needed, just as I was about to start screwing with distance fields or the like. THANK-YOU! Edit: I may have spoken slightly too soon, not since
by watmough 11y ago
Exactly what I needed, just as I was about to start screwing with distance fields or the like. THANK-YOU!
Edit: I may have spoken slightly too soon, not since the technique isn't awesome, but because this isn't yet usable without an atlas generation tool that I don't know how to build.
As far as performance goes, this is rendering a 124-page PDF (I know, just the glyphs...) utterly without lag using the GPU, on a 16 Gbyte quad i7 box that can barely render a couple of pages under OS X Preview without significant pauses. Impressive and Incredible.
- davej 11y agoIt's very laggy and slow on a quad i7 16GB Macbook Pro. Presumably this is because of the retina display.
- watmough 11y agoHere's my experience on my local devices: * Quad i7 16 GBytes GTX 970 OSX FFox - perfectly smooth * iPhone 6s+ - very smooth * Nexus 6p - slightly jumpy / laggy but still impressive * Lumia 640 Windows Phone 10 - dFdx undeclared identifier (120,33) There may be issues with webgl on the MBP if it's using Intel graphics, but I'd be pretty disappointed to get worse performance than an iPhone ... For the curious, the Lumia error appears to stem from this: https://groups.google.com/forum/embed/#!topic/angleproject/-CcKYvupr80 https://groups.google.com/forum/embed/#!topic/angleproject/-...
- davej 11y agoYeah my rMBP uses an embedded Intel graphics card. The performance is horrible, ~2 fps, tried FF and Chrome.
- smskelley 11y agoEven with a discrete card (M370x), the performance is poor on my rMBP. I only tried Chrome, though.
- microcolonel 11y agoPerformance is pretty decent (around 48fps for a full page with lots of glyphs, 1080p) on my Intel HD 4400. This is on linux though. I hear the OS X intel drivers have some shader compiler pitfalls.
- bhauer 11y agoIt's amazingly smooth, I'd say 60+ fps, on my i7-3770K desktop (Geforce GTX970) with Firefox Developer Edition.
- mangecoeur 11y agoGetting perfectly smooth performance on a similar quad i7 16GB Macbook Pro under Firefox 43... perhaps a browser issue?
- green7ea 11y agoI don't think it's because of the retina display. I'm running it very smoothly in Linux at 3200x1800 with an Intel HD4000
- rayiner 11y agoI can scroll that PDF at full speed on my rMBP without significant pauses.
- skybrian 11y agoIt's rather laggy for me. (2011 MacBook Pro.)
- plg 11y agoIt's pretty great on this iPad Air 2
- DonHopkins 11y agoTextMesh Pro comes with an atlas generation tool. See my description above.
- jon-wood 11y agoI find it curious the number of people in this thread being amazed that high end i7 processors and graphics cards designed for gaming can passably render some text. Is there something I'm missing?
- Qantourisc 11y agoIt's not so much they are amazed it capable of doing this. But more of a WOW this is fast compared to rendering theses slow PDF pages on the CPU. It's a bit like saying: wow this rocket propelled car is fast. Are we surprised it is faster ? No. Are we like: "wow we could go faster !"? Yes To be fair, I don't understand why we don't have a lib, or even this stuff build into OpenGL/Direct3D. We are doing raster work CPU's. It's relatively slow.
- corysama 11y agoMicrosoft has Direct2D https://msdn.microsoft.com/en-us/library/windows/desktop/dd370987(v=vs.85).aspx https://msdn.microsoft.com/en-us/library/windows/desktop/dd3... Nvidia has it's nvPathRendering extension to OpenGL https://developer.nvidia.com/nv-path-rendering https://developer.nvidia.com/nv-path-rendering I'm not aware of a fully portable equivalent to either of these two libs.
- vidarh 11y agoThe something you're missing is that we're used to see this done on the CPU, and it's not something CPUs are good at: Pages full of text rendered with scalable fonts involves either a huge number of bezier curves etc. or a huge number of small blits, though you can trade some of it off by spending huge amounts of memory pre-rendering and caching (but if you cache bitmaps at the character level, you will find it harder to do really nice typography - ligatures etc.). It's not that it's that amazing that it's possible on a GPU, but that it's amazing to see the difference.
- joosters 11y agoSorry to sound like an old fart, but computers have been doing this for years, and no, caching rendered glyphs does not eat huge amounts of memory. e.g. RiscOS on ancient ARM processors, drawing sub-pixel anti-aliased text on a CPU that had no floating point. Even just 64kb of font cache to store the bitmaps could keep everything running blazingly fast. Of course, the font renderers have gotten smarter, and of course, screen resolutions have increased, but the difficulties inherent in font renderering are all at the small scale, where you want text to remain crisp even when using only a few pixels.