Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8016715
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T20:37:01+00:00 2026-06-04T20:37:01+00:00

I draw some Shape with openGL command in CCNode. And now I want deal

  • 0

I draw some Shape with openGL command in CCNode. And now I want deal Gaussian Blur with it.
But I can’t find any way to do this.
Anybody recommend?

.

.major of solve code:

    CCRenderTexture *renderTex = [[CCRenderTexture renderTextureWithWidth:480 height: 320] retain];
    renderTex.position = ccp(size.width/2, size.height/2);
    [renderTex begin];
    //here can put any draw code with opengl
    [curve visit];
    [renderTex end];
    CCTexture2DMutable *mutableTexture=[[[CCTexture2DMutable alloc]
                                        initWithImage:[renderTex getUIImageFromBuffer]]autorelease];

    CGRect rect = CGRectMake(0, 0, [mutableTexture contentSizeInPixels].width, [mutableTexture contentSizeInPixels].height);
    [AWTextureFilter blur:mutableTexture radius:8 rect:rect];
    CCSpriteFrame *frame = [CCSpriteFrame frameWithTexture:mutableTexture rect:rect];
    [[CCSpriteFrameCache sharedSpriteFrameCache]addSpriteFrame:frame name:@"1"];
    CCSprite *blur = [CCSprite spriteWithSpriteFrame:frame];
    [blur setPosition:ccp(size.width/2, size.height/2)];
    blur.opacity=200;
    [self addChild:blur];
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T20:37:02+00:00Added an answer on June 4, 2026 at 8:37 pm

    you have to:

    • render the whole scene to the render target (to the texture), you can use Framebuffer Objects
    • then you draw a fullscreen quad with that previuous texture (with the scene) attached.
    • in the end you can perform gussian blur effect (or some other postprocessing effect)

    some info:

    • http://maniacdev.com/2011/07/tutorial-masking-sprites-in-cocos2d-with-ccrendertexture/
    • http://www.songho.ca/opengl/gl_fbo.html
    • http://www.gamerendering.com/2008/10/11/gaussian-blur-filter-shader/
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to draw some text on the wallpaper and make it move, but
I have a project that in those i draw some shape from some layer.
I can use GD or something to draw user-selected shapes by writing some lines
I want to draw some lines and rectangles on a panel. Sometimes it does
I want to draw some listview items disabled and would like to mimic the
I want to draw a shape(many circles particularly) into a Specific Bitmap. I have
I want to draw a String on some shapes following the examples in http://msdn.microsoft.com/en-us/library/aa327572%28v=vs.71%29.aspx
I am trying to create a tool that will draw a shape in openGL
I started playing around with OpenGL and GLUT. I would like to draw some
I'm looking to draw a custom shape (say, a solid rectangle) using openGL ES

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.