SlideShare a Scribd company logo
1 of 29
Download to read offline
Pablo Tesone
Martín Dias
News on Bloc for
ESUG 2023 - Lyon
Thales
Pharo Consortium
What is Bloc?
a low-level UI
infrastructure &
framework for Pharo
geometry
(polygon)
a BlElement
background
border
transformation
(a matrix with
skew and translation)
Element's visual properties
Element's outskirts
aBlElement
outskirts:
BlOutskirts outside
aBlElement
outskirts:
BlOutskirts centered
aBlElement
outskirts:
BlOutskirts inside
Border's cap
vertices := { 50@150. 150@50}.
referenceLine := (BlPolylineGeometry vertices: vertices) asElement.
capLine := (BlPolylineGeometry vertices: vertices) asElement.
capLine border: (BlBorder builder
paint: Color pink;
width: 50;
lineCap: BlStrokeLineCap round;
build)
Border's join
What is Bloc? For API tasting, please watch! ⤵
Bloc for Pharo - ESUG 2022
Pharo VM
harfbuzz.dll
Alexandrie
SDL2.dll
OSWindow
Bloc
cairo.dll freetype.dll
applications
What is Bloc? Architecture
News!
10 things you may
not know of Bloc
in 2023
Bloc and Alexandrie
News
#1
New commits: 874
Closed issues: 65
Closed PR: 43
Total tests: 1287
Alexandrie counts with
222 FFI call bindings.
~100 more than Athens
(we are ready to create an
Athens backend)
New pre-release: Bloc v2.0.0-alpha
Bloc: https://github.com/pharo-graphics/Bloc/releases/tag/v2.0.0-alpha
Alexandrie: https://github.com/pharo-graphics/Alexandrie/releases/tag/v2.0.0-alpha
New projects using Bloc
News
#2
Avoid rasterizing again elements that didn't change
Compositing Layers
News
#3
Only a simple implementation for the moment:
• Any BlElement that answers true to
wantsSeparateCompositingLayer is cached
on a cairo surface (yeah, no GPU yet).
• Such element will be rasterized again only after a
visual property changed (except a position change).
• It must be enabled explicitly by sending
beInSeparateCompositionLayer to a
BlElement.
An example
Compositing Layers
News
#3
The 3 layers are
rasterized only once
(already transformed)
These 3 text elements received
beInSeparateCompositionLayer
Benchmarks show it can help
100 static circles of 200x200 pixels
that move down.
Three
fl
avors:
👉 Dashed Border Circles
👉 Radial Gradient Circles
👉 Translucent Circles
layers: o
f
on
fps 75 125
avg ms 13 8
ratio 1.7X
layers: o
f
on
fps 14 120
avg ms 71 8
ratio 8.6X
layers: o
f
on
fps 28 97
avg ms 35 10
ratio 3.4X
None bu
ff
ered (layers o
f
) vs. All bu
ff
ered (layers on)
fps = Frames Per Second
avg ms = Average ms per Frame
Compositing Layers
Reference: Browse PCBenchmarker in https://github.com/pharo-graphics/BlocBenchs
Harfbuzz ffi bindings
Why? ⤵
It converts a Unicode string into properly formatted and positioned
glyph output (based on font info that cairo+freetype ignore)
News
#4
Bloc-Alexandrie now has
FFI bindings to this C library
Harfbuzz ligatures example
Only Cairo 👉
Harfbuzz + Cairo 👉
Source Sans Pro Cascadia Code
Font
fi
les can provide a ligature glyph
for certain sequences
Harfbuzz emoji example
Zero
Width
Joiner
Zero
Width
Joiner
Zero
Width
Joiner
Harfbuzz
Zero
Width
Joiner
is a Unicode character to explicit "related with"
Pharo VM or OS
Alexandrie
SDL2.dll
OSWindow
Bloc
cairo.dll freetype.dll
applications
👉 Win, Linux, Mac had di
ff
erent versions
👉 Harfbuzz was missing
Lib upgrade instructions were too complex
both for users and for de
fi
ning CI jobs
News
#5
Dynamic libraries
Some work was required
Pharo VM v9.0.21 ~ Dec'22
SDL2
cairo freetype harfbuzz
Now all platforms have:
• Cairo: 1.17.4
• Freetype: 2.12.1
• Harfbuzz: 5.3.1
• SDL: 2.24.1
Dynamic libraries
New VM version did it
👍Consistent CI results
on all platforms
👍 Simplify Bloc
install instructions 👍 Speed-up in
some cases
Dynamic libraries
👇
MacOS had too old (slow) versions!
Frames per second
boosted between
1.8X and 4.4X
According to this benchmark
(18 variations).
300 rounded rectangles
200 x 200 pixels each
each one has a small child
(that is either clipped or not)
Reference: #exampleOutskirts in https://github.com/pharo-graphics/BlocBenchs
News
#6
Use case:
• CI: Emoji regression
test (randomly) fails
• CI: fuel-outs the test's
pixel comparison
• Download it from web
• Drop it into Pharo
• Discover somehow it
is rendered in a single
color!
CI exports regressions
Inspect by dropping a fuel
fi
le
Rounded Rectangle
News
#7
How you see
the test
fi
xture Mouse events were only
dispatched on the colored
regions
After the
fi
x
👍
Bug
fi
x: wrong hit testing
Want to see more?
• Evaluate: BAHitTest inspectAll
• Browse: BlRoundedRectangleGeometry>>#containsPoint:alreadyInGeometryBoundsOf:
Rounded Rectangle
Enhancement: Give more
fl
exibility on corner radii (as in CSS)
Now, a corner
can take 100%
available
Before, each radius
was limited to 50%
of (width min: height)
More info at: https://github.com/pharo-graphics/Bloc/issues/217
Compare
these
corners
Rounded Rectangle
If two corners overlap, all corners are reduced proportionally
Based on CSS spec: https://w3c.github.io/csswg-drafts/css-backgrounds/#corner-overlap
before after
Import SVG
Repair and improve code from BlocPac and Athens-SVG
News
#8
<?xml version="1.0" standalone="no"?>
<svg width="1024" height="1024">
<path d="M512 64C264.6...z"/>
<path d="M232.3 15...z"/>
</svg>
Bloc
importer
More about this change in https://github.com/pharo-graphics/Bloc/pull/296
Export SVG and PDF
As vectors (not just pixels) via cairo API
News
#9
For more information, look at AeCairoPDFSurface and BlPdfExporter
BlElement new
geometry: (BlRoundedRectangleGeometry cornerRadius: 50);
size: 500@100;
border: (BlBorder builder
paint: Color blue;
width: 15;
dashArray: #(20);
build);
effect: (BlGaussianShadowEffect
color: Color orange
width: 20
offset: 20 asPoint);
yourself
News
#10
Gaussian Shadow Effect
Cairo doesn't provide this e
ff
ect, we implemented the algorithm.
It
can
be slow
(not GPU)
Border with gradients
Feature request in Bloc-Alexandrie
News
BONUS
NOW:
Borders can have a linear
or radial gradient as paint
BEFORE:
an element's border could
only have a single color
Mailing-list: lse-openbloc@inria.fr
(subscribe at: http://sympa.inria.fr)
Discord: Pharo server / #bloc channel
Bloc: https://github.com/pharo-graphics/Bloc
Alexandrie: https://github.com/pharo-graphics/Alexandrie
News in Bloc for Pharo
Pablo Tesone
Martín Dias
ESUG 2023 - Lyon
STAY
TUNED!

More Related Content

Similar to News on Bloc for Pharo

Pharo Optimising JIT Internals
Pharo Optimising JIT InternalsPharo Optimising JIT Internals
Pharo Optimising JIT InternalsESUG
 
Front-end God Mode with Reagent and Figwheel
Front-end God Mode with Reagent and FigwheelFront-end God Mode with Reagent and Figwheel
Front-end God Mode with Reagent and FigwheelDavid Kay
 
Dynamic Wounds on Animated Characters in UE4
Dynamic Wounds on Animated Characters in UE4Dynamic Wounds on Animated Characters in UE4
Dynamic Wounds on Animated Characters in UE4Michał Kłoś
 
Clojure: Simple By Design
Clojure: Simple By DesignClojure: Simple By Design
Clojure: Simple By DesignAll Things Open
 
CSS :has() - The story so far and the path ahead
CSS :has() - The story so far and the path aheadCSS :has() - The story so far and the path ahead
CSS :has() - The story so far and the path aheadIgalia
 
CSS :has The story so far and the path ahead
CSS :has   The story so far and the path aheadCSS :has   The story so far and the path ahead
CSS :has The story so far and the path aheadIgalia
 
Let's talks about string operations in C++17
Let's talks about string operations in C++17Let's talks about string operations in C++17
Let's talks about string operations in C++17Bartlomiej Filipek
 
Using line based voronoi in arc gis
Using line based voronoi in arc gisUsing line based voronoi in arc gis
Using line based voronoi in arc gisFabien Ancelin
 
From WCF to gRPC
From WCF to gRPCFrom WCF to gRPC
From WCF to gRPCMark Rendle
 
Using line-based Voronoi cells in GIS
Using line-based Voronoi cells in GISUsing line-based Voronoi cells in GIS
Using line-based Voronoi cells in GISFabien Ancelin
 
Intro to JavaFX & Widget FX
Intro to JavaFX & Widget FXIntro to JavaFX & Widget FX
Intro to JavaFX & Widget FXStephen Chin
 
Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...
Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...
Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...Samsung Open Source Group
 
HES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARF
HES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARFHES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARF
HES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARFHackito Ergo Sum
 
Making CSS and Firebug Your New Friends
Making CSS and Firebug Your New FriendsMaking CSS and Firebug Your New Friends
Making CSS and Firebug Your New Friendscdw9
 
PIL - A Platform Independent Language
PIL - A Platform Independent LanguagePIL - A Platform Independent Language
PIL - A Platform Independent Languagezefhemel
 
Javaone2008 Bof 5102 Groovybuilders
Javaone2008 Bof 5102 GroovybuildersJavaone2008 Bof 5102 Groovybuilders
Javaone2008 Bof 5102 GroovybuildersAndres Almiray
 
How Shit Works - Source Maps
How Shit Works - Source MapsHow Shit Works - Source Maps
How Shit Works - Source MapsAdir Amsalem
 

Similar to News on Bloc for Pharo (20)

Pharo Optimising JIT Internals
Pharo Optimising JIT InternalsPharo Optimising JIT Internals
Pharo Optimising JIT Internals
 
Front-end God Mode with Reagent and Figwheel
Front-end God Mode with Reagent and FigwheelFront-end God Mode with Reagent and Figwheel
Front-end God Mode with Reagent and Figwheel
 
Dynamic Wounds on Animated Characters in UE4
Dynamic Wounds on Animated Characters in UE4Dynamic Wounds on Animated Characters in UE4
Dynamic Wounds on Animated Characters in UE4
 
CSS3 3D Workshop
CSS3 3D WorkshopCSS3 3D Workshop
CSS3 3D Workshop
 
Clojure: Simple By Design
Clojure: Simple By DesignClojure: Simple By Design
Clojure: Simple By Design
 
CSS :has() - The story so far and the path ahead
CSS :has() - The story so far and the path aheadCSS :has() - The story so far and the path ahead
CSS :has() - The story so far and the path ahead
 
CSS :has The story so far and the path ahead
CSS :has   The story so far and the path aheadCSS :has   The story so far and the path ahead
CSS :has The story so far and the path ahead
 
Let's talks about string operations in C++17
Let's talks about string operations in C++17Let's talks about string operations in C++17
Let's talks about string operations in C++17
 
Using line based voronoi in arc gis
Using line based voronoi in arc gisUsing line based voronoi in arc gis
Using line based voronoi in arc gis
 
From WCF to gRPC
From WCF to gRPCFrom WCF to gRPC
From WCF to gRPC
 
Zero con2019
Zero con2019Zero con2019
Zero con2019
 
Using line-based Voronoi cells in GIS
Using line-based Voronoi cells in GISUsing line-based Voronoi cells in GIS
Using line-based Voronoi cells in GIS
 
Intro to JavaFX & Widget FX
Intro to JavaFX & Widget FXIntro to JavaFX & Widget FX
Intro to JavaFX & Widget FX
 
Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...
Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...
Stealing Chromium: Embedding HTML5 with the Servo Browser Engine (LinuxCon NA...
 
HES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARF
HES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARFHES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARF
HES2011 - James Oakley and Sergey bratus-Exploiting-the-Hard-Working-DWARF
 
Making CSS and Firebug Your New Friends
Making CSS and Firebug Your New FriendsMaking CSS and Firebug Your New Friends
Making CSS and Firebug Your New Friends
 
Pixel shaders
Pixel shadersPixel shaders
Pixel shaders
 
PIL - A Platform Independent Language
PIL - A Platform Independent LanguagePIL - A Platform Independent Language
PIL - A Platform Independent Language
 
Javaone2008 Bof 5102 Groovybuilders
Javaone2008 Bof 5102 GroovybuildersJavaone2008 Bof 5102 Groovybuilders
Javaone2008 Bof 5102 Groovybuilders
 
How Shit Works - Source Maps
How Shit Works - Source MapsHow Shit Works - Source Maps
How Shit Works - Source Maps
 

More from ESUG

Workshop: Identifying concept inventories in agile programming
Workshop: Identifying concept inventories in agile programmingWorkshop: Identifying concept inventories in agile programming
Workshop: Identifying concept inventories in agile programmingESUG
 
Technical documentation support in Pharo
Technical documentation support in PharoTechnical documentation support in Pharo
Technical documentation support in PharoESUG
 
The Pharo Debugger and Debugging tools: Advances and Roadmap
The Pharo Debugger and Debugging tools: Advances and RoadmapThe Pharo Debugger and Debugging tools: Advances and Roadmap
The Pharo Debugger and Debugging tools: Advances and RoadmapESUG
 
Sequence: Pipeline modelling in Pharo
Sequence: Pipeline modelling in PharoSequence: Pipeline modelling in Pharo
Sequence: Pipeline modelling in PharoESUG
 
Migration process from monolithic to micro frontend architecture in mobile ap...
Migration process from monolithic to micro frontend architecture in mobile ap...Migration process from monolithic to micro frontend architecture in mobile ap...
Migration process from monolithic to micro frontend architecture in mobile ap...ESUG
 
Analyzing Dart Language with Pharo: Report and early results
Analyzing Dart Language with Pharo: Report and early resultsAnalyzing Dart Language with Pharo: Report and early results
Analyzing Dart Language with Pharo: Report and early resultsESUG
 
Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6
Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6
Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6ESUG
 
A Unit Test Metamodel for Test Generation
A Unit Test Metamodel for Test GenerationA Unit Test Metamodel for Test Generation
A Unit Test Metamodel for Test GenerationESUG
 
Creating Unit Tests Using Genetic Programming
Creating Unit Tests Using Genetic ProgrammingCreating Unit Tests Using Genetic Programming
Creating Unit Tests Using Genetic ProgrammingESUG
 
Threaded-Execution and CPS Provide Smooth Switching Between Execution Modes
Threaded-Execution and CPS Provide Smooth Switching Between Execution ModesThreaded-Execution and CPS Provide Smooth Switching Between Execution Modes
Threaded-Execution and CPS Provide Smooth Switching Between Execution ModesESUG
 
Exploring GitHub Actions through EGAD: An Experience Report
Exploring GitHub Actions through EGAD: An Experience ReportExploring GitHub Actions through EGAD: An Experience Report
Exploring GitHub Actions through EGAD: An Experience ReportESUG
 
Pharo: a reflective language A first systematic analysis of reflective APIs
Pharo: a reflective language A first systematic analysis of reflective APIsPharo: a reflective language A first systematic analysis of reflective APIs
Pharo: a reflective language A first systematic analysis of reflective APIsESUG
 
Garbage Collector Tuning
Garbage Collector TuningGarbage Collector Tuning
Garbage Collector TuningESUG
 
Improving Performance Through Object Lifetime Profiling: the DataFrame Case
Improving Performance Through Object Lifetime Profiling: the DataFrame CaseImproving Performance Through Object Lifetime Profiling: the DataFrame Case
Improving Performance Through Object Lifetime Profiling: the DataFrame CaseESUG
 
Pharo DataFrame: Past, Present, and Future
Pharo DataFrame: Past, Present, and FuturePharo DataFrame: Past, Present, and Future
Pharo DataFrame: Past, Present, and FutureESUG
 
thisContext in the Debugger
thisContext in the DebuggerthisContext in the Debugger
thisContext in the DebuggerESUG
 
Websockets for Fencing Score
Websockets for Fencing ScoreWebsockets for Fencing Score
Websockets for Fencing ScoreESUG
 
ShowUs: PharoJS.org Develop in Pharo, Run on JavaScript
ShowUs: PharoJS.org Develop in Pharo, Run on JavaScriptShowUs: PharoJS.org Develop in Pharo, Run on JavaScript
ShowUs: PharoJS.org Develop in Pharo, Run on JavaScriptESUG
 
Advanced Object- Oriented Design Mooc
Advanced Object- Oriented Design MoocAdvanced Object- Oriented Design Mooc
Advanced Object- Oriented Design MoocESUG
 
A New Architecture Reconciling Refactorings and Transformations
A New Architecture Reconciling Refactorings and TransformationsA New Architecture Reconciling Refactorings and Transformations
A New Architecture Reconciling Refactorings and TransformationsESUG
 

More from ESUG (20)

Workshop: Identifying concept inventories in agile programming
Workshop: Identifying concept inventories in agile programmingWorkshop: Identifying concept inventories in agile programming
Workshop: Identifying concept inventories in agile programming
 
Technical documentation support in Pharo
Technical documentation support in PharoTechnical documentation support in Pharo
Technical documentation support in Pharo
 
The Pharo Debugger and Debugging tools: Advances and Roadmap
The Pharo Debugger and Debugging tools: Advances and RoadmapThe Pharo Debugger and Debugging tools: Advances and Roadmap
The Pharo Debugger and Debugging tools: Advances and Roadmap
 
Sequence: Pipeline modelling in Pharo
Sequence: Pipeline modelling in PharoSequence: Pipeline modelling in Pharo
Sequence: Pipeline modelling in Pharo
 
Migration process from monolithic to micro frontend architecture in mobile ap...
Migration process from monolithic to micro frontend architecture in mobile ap...Migration process from monolithic to micro frontend architecture in mobile ap...
Migration process from monolithic to micro frontend architecture in mobile ap...
 
Analyzing Dart Language with Pharo: Report and early results
Analyzing Dart Language with Pharo: Report and early resultsAnalyzing Dart Language with Pharo: Report and early results
Analyzing Dart Language with Pharo: Report and early results
 
Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6
Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6
Transpiling Pharo Classes to JS ECMAScript 5 versus ECMAScript 6
 
A Unit Test Metamodel for Test Generation
A Unit Test Metamodel for Test GenerationA Unit Test Metamodel for Test Generation
A Unit Test Metamodel for Test Generation
 
Creating Unit Tests Using Genetic Programming
Creating Unit Tests Using Genetic ProgrammingCreating Unit Tests Using Genetic Programming
Creating Unit Tests Using Genetic Programming
 
Threaded-Execution and CPS Provide Smooth Switching Between Execution Modes
Threaded-Execution and CPS Provide Smooth Switching Between Execution ModesThreaded-Execution and CPS Provide Smooth Switching Between Execution Modes
Threaded-Execution and CPS Provide Smooth Switching Between Execution Modes
 
Exploring GitHub Actions through EGAD: An Experience Report
Exploring GitHub Actions through EGAD: An Experience ReportExploring GitHub Actions through EGAD: An Experience Report
Exploring GitHub Actions through EGAD: An Experience Report
 
Pharo: a reflective language A first systematic analysis of reflective APIs
Pharo: a reflective language A first systematic analysis of reflective APIsPharo: a reflective language A first systematic analysis of reflective APIs
Pharo: a reflective language A first systematic analysis of reflective APIs
 
Garbage Collector Tuning
Garbage Collector TuningGarbage Collector Tuning
Garbage Collector Tuning
 
Improving Performance Through Object Lifetime Profiling: the DataFrame Case
Improving Performance Through Object Lifetime Profiling: the DataFrame CaseImproving Performance Through Object Lifetime Profiling: the DataFrame Case
Improving Performance Through Object Lifetime Profiling: the DataFrame Case
 
Pharo DataFrame: Past, Present, and Future
Pharo DataFrame: Past, Present, and FuturePharo DataFrame: Past, Present, and Future
Pharo DataFrame: Past, Present, and Future
 
thisContext in the Debugger
thisContext in the DebuggerthisContext in the Debugger
thisContext in the Debugger
 
Websockets for Fencing Score
Websockets for Fencing ScoreWebsockets for Fencing Score
Websockets for Fencing Score
 
ShowUs: PharoJS.org Develop in Pharo, Run on JavaScript
ShowUs: PharoJS.org Develop in Pharo, Run on JavaScriptShowUs: PharoJS.org Develop in Pharo, Run on JavaScript
ShowUs: PharoJS.org Develop in Pharo, Run on JavaScript
 
Advanced Object- Oriented Design Mooc
Advanced Object- Oriented Design MoocAdvanced Object- Oriented Design Mooc
Advanced Object- Oriented Design Mooc
 
A New Architecture Reconciling Refactorings and Transformations
A New Architecture Reconciling Refactorings and TransformationsA New Architecture Reconciling Refactorings and Transformations
A New Architecture Reconciling Refactorings and Transformations
 

Recently uploaded

Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝soniya singh
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number SystemsJheuzeDellosa
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationkaushalgiri8080
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
What is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWhat is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWave PLM
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software DevelopersVinodh Ram
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...Christina Lin
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxTier1 app
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningVitsRangannavar
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...aditisharan08
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptkotipi9215
 
buds n tech IT solutions
buds n  tech IT                solutionsbuds n  tech IT                solutions
buds n tech IT solutionsmonugehlot87
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样umasea
 

Recently uploaded (20)

Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
Call Girls in Naraina Delhi 💯Call Us 🔝8264348440🔝
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number Systems
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Project Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanationProject Based Learning (A.I).pptx detail explanation
Project Based Learning (A.I).pptx detail explanation
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
What is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need ItWhat is Fashion PLM and Why Do You Need It
What is Fashion PLM and Why Do You Need It
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software Developers
 
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
ODSC - Batch to Stream workshop - integration of Apache Spark, Cassandra, Pos...
 
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptxKnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
KnowAPIs-UnknownPerf-jaxMainz-2024 (1).pptx
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
cybersecurity notes for mca students for learning
cybersecurity notes for mca students for learningcybersecurity notes for mca students for learning
cybersecurity notes for mca students for learning
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.ppt
 
buds n tech IT solutions
buds n  tech IT                solutionsbuds n  tech IT                solutions
buds n tech IT solutions
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
 

News on Bloc for Pharo

  • 1. Pablo Tesone Martín Dias News on Bloc for ESUG 2023 - Lyon Thales Pharo Consortium
  • 2. What is Bloc? a low-level UI infrastructure & framework for Pharo
  • 3. geometry (polygon) a BlElement background border transformation (a matrix with skew and translation) Element's visual properties
  • 5. Border's cap vertices := { 50@150. 150@50}. referenceLine := (BlPolylineGeometry vertices: vertices) asElement. capLine := (BlPolylineGeometry vertices: vertices) asElement. capLine border: (BlBorder builder paint: Color pink; width: 50; lineCap: BlStrokeLineCap round; build)
  • 7. What is Bloc? For API tasting, please watch! ⤵ Bloc for Pharo - ESUG 2022
  • 9. News! 10 things you may not know of Bloc in 2023
  • 10. Bloc and Alexandrie News #1 New commits: 874 Closed issues: 65 Closed PR: 43 Total tests: 1287 Alexandrie counts with 222 FFI call bindings. ~100 more than Athens (we are ready to create an Athens backend) New pre-release: Bloc v2.0.0-alpha Bloc: https://github.com/pharo-graphics/Bloc/releases/tag/v2.0.0-alpha Alexandrie: https://github.com/pharo-graphics/Alexandrie/releases/tag/v2.0.0-alpha
  • 11. New projects using Bloc News #2
  • 12. Avoid rasterizing again elements that didn't change Compositing Layers News #3 Only a simple implementation for the moment: • Any BlElement that answers true to wantsSeparateCompositingLayer is cached on a cairo surface (yeah, no GPU yet). • Such element will be rasterized again only after a visual property changed (except a position change). • It must be enabled explicitly by sending beInSeparateCompositionLayer to a BlElement.
  • 13. An example Compositing Layers News #3 The 3 layers are rasterized only once (already transformed) These 3 text elements received beInSeparateCompositionLayer
  • 14. Benchmarks show it can help 100 static circles of 200x200 pixels that move down. Three fl avors: 👉 Dashed Border Circles 👉 Radial Gradient Circles 👉 Translucent Circles layers: o f on fps 75 125 avg ms 13 8 ratio 1.7X layers: o f on fps 14 120 avg ms 71 8 ratio 8.6X layers: o f on fps 28 97 avg ms 35 10 ratio 3.4X None bu ff ered (layers o f ) vs. All bu ff ered (layers on) fps = Frames Per Second avg ms = Average ms per Frame Compositing Layers Reference: Browse PCBenchmarker in https://github.com/pharo-graphics/BlocBenchs
  • 15. Harfbuzz ffi bindings Why? ⤵ It converts a Unicode string into properly formatted and positioned glyph output (based on font info that cairo+freetype ignore) News #4 Bloc-Alexandrie now has FFI bindings to this C library
  • 16. Harfbuzz ligatures example Only Cairo 👉 Harfbuzz + Cairo 👉 Source Sans Pro Cascadia Code Font fi les can provide a ligature glyph for certain sequences
  • 18. Pharo VM or OS Alexandrie SDL2.dll OSWindow Bloc cairo.dll freetype.dll applications 👉 Win, Linux, Mac had di ff erent versions 👉 Harfbuzz was missing Lib upgrade instructions were too complex both for users and for de fi ning CI jobs News #5 Dynamic libraries Some work was required
  • 19. Pharo VM v9.0.21 ~ Dec'22 SDL2 cairo freetype harfbuzz Now all platforms have: • Cairo: 1.17.4 • Freetype: 2.12.1 • Harfbuzz: 5.3.1 • SDL: 2.24.1 Dynamic libraries New VM version did it 👍Consistent CI results on all platforms 👍 Simplify Bloc install instructions 👍 Speed-up in some cases
  • 20. Dynamic libraries 👇 MacOS had too old (slow) versions! Frames per second boosted between 1.8X and 4.4X According to this benchmark (18 variations). 300 rounded rectangles 200 x 200 pixels each each one has a small child (that is either clipped or not) Reference: #exampleOutskirts in https://github.com/pharo-graphics/BlocBenchs
  • 21. News #6 Use case: • CI: Emoji regression test (randomly) fails • CI: fuel-outs the test's pixel comparison • Download it from web • Drop it into Pharo • Discover somehow it is rendered in a single color! CI exports regressions Inspect by dropping a fuel fi le
  • 22. Rounded Rectangle News #7 How you see the test fi xture Mouse events were only dispatched on the colored regions After the fi x 👍 Bug fi x: wrong hit testing Want to see more? • Evaluate: BAHitTest inspectAll • Browse: BlRoundedRectangleGeometry>>#containsPoint:alreadyInGeometryBoundsOf:
  • 23. Rounded Rectangle Enhancement: Give more fl exibility on corner radii (as in CSS) Now, a corner can take 100% available Before, each radius was limited to 50% of (width min: height) More info at: https://github.com/pharo-graphics/Bloc/issues/217
  • 24. Compare these corners Rounded Rectangle If two corners overlap, all corners are reduced proportionally Based on CSS spec: https://w3c.github.io/csswg-drafts/css-backgrounds/#corner-overlap before after
  • 25. Import SVG Repair and improve code from BlocPac and Athens-SVG News #8 <?xml version="1.0" standalone="no"?> <svg width="1024" height="1024"> <path d="M512 64C264.6...z"/> <path d="M232.3 15...z"/> </svg> Bloc importer More about this change in https://github.com/pharo-graphics/Bloc/pull/296
  • 26. Export SVG and PDF As vectors (not just pixels) via cairo API News #9 For more information, look at AeCairoPDFSurface and BlPdfExporter
  • 27. BlElement new geometry: (BlRoundedRectangleGeometry cornerRadius: 50); size: 500@100; border: (BlBorder builder paint: Color blue; width: 15; dashArray: #(20); build); effect: (BlGaussianShadowEffect color: Color orange width: 20 offset: 20 asPoint); yourself News #10 Gaussian Shadow Effect Cairo doesn't provide this e ff ect, we implemented the algorithm. It can be slow (not GPU)
  • 28. Border with gradients Feature request in Bloc-Alexandrie News BONUS NOW: Borders can have a linear or radial gradient as paint BEFORE: an element's border could only have a single color
  • 29. Mailing-list: lse-openbloc@inria.fr (subscribe at: http://sympa.inria.fr) Discord: Pharo server / #bloc channel Bloc: https://github.com/pharo-graphics/Bloc Alexandrie: https://github.com/pharo-graphics/Alexandrie News in Bloc for Pharo Pablo Tesone Martín Dias ESUG 2023 - Lyon STAY TUNED!