Groups
Groups
Sign in
Groups
Groups
skia-discuss
Conversations
About
Send feedback
Help
Combining skia and opengl 3d
524 views
Skip to first unread message
Zhenobi MCPE
unread,
Dec 25, 2019, 1:37:05 AM
12/25/19
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to skia-discuss
Drawing opengl or skia cancel each other out. What is the proper way to combine them?
KnIfER
unread,
Sep 7, 2021, 7:30:54 AM
9/7/21
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to skia-discuss
wglMakeCurrent...
// reset gl states[1]
glEnable(GL_CULL_FACE);
glUseProgram(0);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
gl draw ...
// reset skia gl context
context->resetContext(GrGLBackendState::kALL_GrGLBackendState);
skia draw ...
Full demo source :
https://github.com/KnIfER/Textrument-Plugins/blob/372122b5a7ec7ba98f288aea9c24f160eb8d9b29/DirectUILib/SkiaTests/GLSkiaHelloWorld.cpp
Not perfect. In this demo the cube gets streched after the window is resized.
[1]:
https://github.com/mono/SkiaSharp/issues/614
Reply all
Reply to author
Forward
0 new messages