MCPcopy Create free account
hub / github.com/axmolengine/axmol / setBlendAdditive

Method setBlendAdditive

core/2d/ParticleSystem.cpp:1903–1916  ·  view source on GitHub ↗

ParticleSystem - Additive Blending

Source from the content-addressed store, hash-verified

1901
1902// ParticleSystem - Additive Blending
1903void ParticleSystem::setBlendAdditive(bool additive)
1904{
1905 if (additive)
1906 {
1907 _blendFunc = BlendFunc::ADDITIVE;
1908 }
1909 else
1910 {
1911 if (_texture && !_texture->hasPremultipliedAlpha())
1912 _blendFunc = BlendFunc::ALPHA_NON_PREMULTIPLIED;
1913 else
1914 _blendFunc = BlendFunc::ALPHA_PREMULTIPLIED;
1915 }
1916}
1917
1918bool ParticleSystem::isBlendAdditive() const
1919{

Callers 2

onEnterMethod · 0.80

Calls 1

hasPremultipliedAlphaMethod · 0.80

Tested by 1

onEnterMethod · 0.64