summaryrefslogtreecommitdiffstats
path: root/glow/src/triangle.rs
diff options
context:
space:
mode:
Diffstat (limited to 'glow/src/triangle.rs')
-rw-r--r--glow/src/triangle.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/glow/src/triangle.rs b/glow/src/triangle.rs
index d0205e08..11d24349 100644
--- a/glow/src/triangle.rs
+++ b/glow/src/triangle.rs
@@ -9,6 +9,9 @@ use iced_graphics::triangle::{ColoredVertex2D, Vertex2D};
use glow::HasContext;
use std::marker::PhantomData;
+#[cfg(feature = "trace")]
+use iced_profiling::info_span;
+
const DEFAULT_VERTICES: usize = 1_000;
const DEFAULT_INDICES: usize = 1_000;
@@ -58,6 +61,9 @@ impl Pipeline {
transformation: Transformation,
scale_factor: f32,
) {
+ #[cfg(feature = "trace")]
+ let _ = info_span!("Glow::Triangle", "DRAW").enter();
+
unsafe {
gl.enable(glow::MULTISAMPLE);
gl.enable(glow::SCISSOR_TEST);