texture border not supported on mobile
This commit is contained in:
@@ -1082,16 +1082,17 @@ bool Canvas::create(int width, int height)
|
||||
#if defined(__IOS__) || defined(__ANDROID__)
|
||||
m_tmp[i].create(width, height, -1, GL_RGBA8);
|
||||
m_tex[i].create(width, height, GL_RGBA8);
|
||||
m_sampler_brush.create();
|
||||
#else
|
||||
m_tmp[i].create(width, height, -1, GL_RGBA32F);
|
||||
m_tex[i].create(width, height, GL_RGBA32F);
|
||||
m_sampler_brush.create(GL_LINEAR, GL_CLAMP_TO_BORDER);
|
||||
#endif
|
||||
m_tex2[i].create(width, height, GL_RGBA8); // TODO: destroy before recreating
|
||||
}
|
||||
m_sampler.create(GL_NEAREST);
|
||||
m_sampler.create(GL_LINEAR);
|
||||
m_sampler_nearest.create(GL_NEAREST);
|
||||
m_sampler_brush.create(GL_LINEAR, GL_CLAMP_TO_BORDER);
|
||||
m_sampler_brush.set_filter(GL_LINEAR_MIPMAP_LINEAR, GL_LINEAR);
|
||||
m_sampler_brush.set_border({ 1, 1, 1, 1 });
|
||||
m_sampler_bg.create(GL_NEAREST);
|
||||
|
||||
Reference in New Issue
Block a user