Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Siile

Pages: [1]
1
SFML projects / Re: Ninja teaser
« on: January 03, 2014, 11:22:11 am »
Hah, still alive and stabbing!  ;D


2
SFML projects / Re: Ninja teaser
« on: November 16, 2013, 03:32:50 pm »
Oh well, GLSL it is (I'm not that good what comes to remembering names, as you might have noticed by now).  ;D

And I mean that shaders (how awesome they might be) shouldn't slow down fps.

3
SFML projects / Re: Ninja teaser
« on: November 16, 2013, 12:27:57 pm »
Anyone worked with OSL & 2D?
Open Software License or Open Source Lighting or Open Shading Language?  ;)

I meantioned shaders so it should be kinda obvious, but in any case, I meant Open Shading Language.  8)

4
SFML projects / Re: Ninja teaser
« on: November 15, 2013, 08:07:03 pm »
Anyone worked with OSL & 2D?

I'm trying to create cool and fast-to-draw effects using shaders (and combining them with particles and sprite animations). If anyone wants to exchange ideas now is a perfect change to do so. ;)


5
SFML projects / Re: Ninja teaser
« on: November 15, 2013, 01:17:08 pm »
Looking good! :)

Are you using any animation software like for example Spine?

Yeah, Spine it is! I'm looking forward for their new kickstarter features to be implemented.


Blood still looks like big red drops of snot to me. :P
Btw. just ignore crappy quality of skin texture and sharingan symbol in the back. Done some major changes lately and testing some new features. ;)

6
SFML projects / Re: Ninja teaser
« on: November 15, 2013, 12:47:07 pm »
The artwork is great, so just let's get excited for next week  :D

Thanks! I wish we had someone who could create awesome skins for different ninja clans...

Btw. I'm not promising to send gameplay demo next week, but there's faint possibility to it (really faint). Or maybe I'll just wait till I can finish the first online gamemode (I mean beta of it) so you can try it for yourselves. ;)

7
SFML projects / Ninja teaser
« on: November 15, 2013, 12:23:34 pm »


I'd post the engine demo (vid), but I'm going to rewrite the physics next week so... ;)

8
SFML projects / Re: What are you working on?
« on: October 07, 2013, 02:43:45 pm »
Something nice...  ;D



And if anyone wonders, skeletons (Spine <3) make animating 2d super easy.

9
Graphics / Re: sf::Texture and sf::RenderTexture.getTexture
« on: September 13, 2013, 07:08:43 am »
Instead of transparent white have you tried using transparent black?

renderTexture.clear(sf::Color(0, 0, 0, 0));

10
Graphics / Re: Rendering to sf::Texture
« on: September 12, 2013, 06:01:05 pm »
I got it working by removing ninjaRender[ninjaNum]->display(); from my source. Dunno why..

The same code using regular texture actually works. As it does when using openGL-rendered RendererTexture. My RenderTexture is drawn like this: myRenderTexture->draw(*stuff))

When I have my RenderTexture using sfml's draw()-method I can use display()-command. However when I use openGL for rendering my RenderTexture, if I used display() when rendering to RenderTexture, it will show but mess up other openGL-drawings.

Question: Is there disadvantages when not using display() when rendering to RenderTexture? Memory leaks or something nasty hidden behind the structures?

Works fine now anyway.  :)


Have you tried using window.pushGLStates() and window.popGLStates() as described in this tutorial http://sfml-dev.org/tutorials/2.1/window-opengl.php ?

 Oh plz! ;D

ps. The same code works fine with regular textures.

11
Graphics / Re: Rendering to sf::Texture
« on: September 11, 2013, 09:02:51 pm »
Example (right from the source):

I initialize my RenderTextures:
Code: [Select]
sf::RenderTexture ninjaRender[maxPlayers];
...
for (int i = 0; i < maxPlayers; i++)
{
ninjaRender[i].create(256, 256);
ninjaRender[i].setView(*ninjaRenderView);
ninjaRender[i].clear(sf::Color(0, 0, 0, 0));
ninjaRender[i].display();
}

Then I cap and draw them:
Code: [Select]
ninjaRender[ninjaNum].clear(sf::Color(0, 0, 0, 0));
ninjaRender[ninjaNum].draw(*anim->drawable);
ninjaRender[ninjaNum].display();

mainWindow->draw(sf::Sprite(ninjaRender[ninjaNum].getTexture()));

Works (nvm crappy solutions, just testing).

However, when I try this:

Code: [Select]
glEnable(GL_TEXTURE_2D);
sf::Texture::bind(&ninjaRender[ninjaNum].getTexture());

glColor4f(1.0f, 1.0f, 1.0f, 1.0f);

glBegin(GL_QUADS);
glTexCoord2f(0.0f, 1.0f); glVertex2f(0, 0);
glTexCoord2f(1.0f, 1.0f); glVertex2f(256, 0);
glTexCoord2f(1.0f, 0.0f); glVertex2f(256, 256);
glTexCoord2f(0.0f, 0.0f); glVertex2f(0, 256);
glEnd();

...it breaks everything.

12
Graphics / Re: Rendering to sf::Texture
« on: September 11, 2013, 06:54:00 pm »
1 more question (before the next one)!  ;D

If I use sfml:s draw-commands to render to texture I cant use openGL to draw it? At least looks so, my game is going wild each time I try it. :P

13
Graphics / Re: Rendering to sf::Texture
« on: September 10, 2013, 07:43:22 pm »
Thanks! This makes things super easy!  ;D

14
Graphics / Re: Rendering to sf::Texture
« on: September 10, 2013, 06:50:32 pm »
You can draw to an sf::RenderTexture.

Thanks!

Can I do this and draw opengl to RenderTexture? That'd give some great possibilities with line of sight and dark blurred areas.
Code: [Select]
sf::Texture::bind(myRenderTexture);

15
Graphics / Rendering to sf::Texture
« on: September 10, 2013, 05:41:01 pm »
Hi ppl!

I'm creating this most awesome 2d multiplayer ninja game using bone animations and all kinds of cool stuff. I was wondering is there's good and fast way to render sfml-draw-using-stuff directly into a texture. I'd do this with opengl but Spine (awesome bone animation tool btw) is using sfml's draw-commands (which I dont want to use that much. For anything else sfml is cool).

I need to render the bone animation to texture for cool shader effects (e.g. motion blur and chakra flow visuals in ninja game anyone?). I'm sending the texture to different shaders for processing before rendering to screen.

Any fast way to do this?


And to all opengl & sfml experts: Will this be too slow if done 20 times in a frame? (Shaders will be super light)

Pages: [1]