1#![cfg_attr(feature = "cargo-clippy", allow(clippy::cast_ptr_alignment))]
2#![cfg_attr(feature = "cargo-clippy", allow(clippy::trivially_copy_pass_by_ref))]
3
4use glib::translate::*;
5
6#[macro_use]
7extern crate glib;
8
9#[macro_use]
10extern crate bitflags;
11
12#[cfg_attr(feature = "cargo-clippy", allow(clippy::type_complexity))]
13#[cfg_attr(feature = "cargo-clippy", allow(clippy::unreadable_literal))]
14mod auto;
15pub use auto::*;
16
17mod debug_object_type_info;
18pub use debug_object_type_info::DebugObjectTypeInfo;
19
20mod depth_state;
21pub use depth_state::DepthState;
22
23mod fence_closure;
24pub use fence_closure::FenceClosure;
25
26mod fence;
27pub use fence::Fence;
28
29mod gles2_vtable;
30pub use gles2_vtable::GLES2Vtable;
31
32mod gtype_object;
33pub use gtype_object::GtypeObject;
34
35mod handle;
36pub use handle::Handle;
37
38mod kms_crtc;
39pub use kms_crtc::KmsCrtc;
40
41mod material;
42pub use material::Material;
43
44mod material_layer;
45pub use material_layer::MaterialLayer;
46
47mod onscreen_dirty_info;
48pub use onscreen_dirty_info::OnscreenDirtyInfo;
49
50mod poll_fd;
51pub use poll_fd::PollFD;
52
53mod texture_vertex;
54pub use texture_vertex::TextureVertex;
55
56mod user_data_key;
57pub use user_data_key::UserDataKey;
58
59mod vertex_p2;
60pub use vertex_p2::VertexP2;
61
62mod vertex_p2c4;
63pub use vertex_p2c4::VertexP2C4;
64
65mod vertex_p2t2;
66pub use vertex_p2t2::VertexP2T2;
67
68mod vertex_p2t2c4;
69pub use vertex_p2t2c4::VertexP2T2C4;
70
71mod vertex_p3;
72pub use vertex_p3::VertexP3;
73
74mod vertex_p3c4;
75pub use vertex_p3c4::VertexP3C4;
76
77mod vertex_p3t2;
78pub use vertex_p3t2::VertexP3T2;
79
80mod vertex_p3t2c4;
81pub use vertex_p3t2c4::VertexP3T2C4;
82
83pub(crate) const TRUE: i32 = ::glib_sys::GTRUE;
84pub fn source_new(context: &Context, priority: glib::Priority) -> glib::Source {
87 unsafe {
88 let source = ffi::cogl_glib_source_new(context.to_glib_none().0, priority.to_glib());
89 from_glib_full(source)
90 }
91}
92
93#[cfg(test)]
107mod tests {
108 #[test]
109 fn it_works() {
110 assert_eq!(2 + 2, 4);
111 }
112}