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 - Alia5

Pages: 1 [2] 3
16
SFML projects / Re: Screenshot Thread
« on: February 07, 2017, 08:39:37 am »
I kinda start digging this shaderstuff...


17
SFML projects / Re: Screenshot Thread
« on: January 31, 2017, 04:08:08 am »
Had a little fun with normal mapping and specular mapping :)

you can get a better quality video here

18
SFML projects / Re: Screenshot Thread
« on: January 16, 2017, 10:17:26 am »
Been playing a bit with SFML, Box2D and Cmdu76s LTBL2 version lately.

(click me)

19
Window / [HOWTO] Make Transparent SFML Window (on Windows 7+)
« on: November 14, 2016, 03:00:12 am »
It got asked multiple times here in the forums, and I've finally found THE solution after a lot of googeling, and it works like a charm.

I wanted to share this here, so it can be easily found via Google and help other since I didn't find this all too quickly.


With this method, "window.clear(sf::color::transparent);" effectively works like you would expect it.

No setting shapes, no masking, no nothing.

Everything not overlayed with shapes / sprites whatever is fully transparent.
Everything you draw is there, even if it is semi transparent.
Even frigging steam overlay works as you'd might expect!

Screenie:


Code:
https://gist.github.com/Alia5/5d8c48941d1f73c1ef14967a5ffe33d5

20
I hoped that you understand, but well it's no problem ;)

You're right... i dunno what i had in code before but now it works.. o.O

i should sleep more

sorry for wasting time...

edit: found my already solved problem... i also have top copy the textures somewhere in the renderring-class
seems like textures aren't completely stored in sprites...

21
Dang -.- ...
Had to set the same context in both threads and now it works like charm...

What you mean with "You don't need to use the window's context, you can use a new one."
If it automatically creates a new context, then it draws nothing, which was my problem.
Well, anyways you helped me out! Thank you! :)

22
Hi there,

I have seperate render-class of wich one function runs in a seperate sf::Thread to draw...
In another thread i want to load my textures and sprites, and manipulate them there

So far so good.

but if i want to load a texture, i have to activate the window in the thread i want to load the texture, wich would pause rendering.

so...
Something like this works:
// create the window
//...

//set up the renderclass
Render renderer;
renderer.setwindow.....
...
//load textures and set up sprites...
//copy them into render class
window.setActive(false);
sf::Thread renderthr(&Render::renderthread, &render);   // create our renderer-thread
renderthr.launch();   //start the renderer


and something like this gives me a blank screen and doesn't draw anything
// create the window
//...
window.setActive(false);
//set up the renderclass
Render renderer;
renderer.setwindow.....
...
//load textures and set up sprites...
//copy them into render class
sf::Thread renderthr(&Render::renderthread, &render);   // create our renderer-thread
renderthr.launch();   //start the renderer

i hope this is enough code to explain my problem...
basically something like
renderer.pause(true);
window.setactive(true);
//loadmytexture and create the sprite
//copy the sprity into the rendererclass
window.setactive(false);
renderer.pause(false);
 
would work but that is suboptimal...

23
with or without sleep, doesnt matter ;) btw: that first post is years old and i was using 1.6 back then...


other non-sfml opengl-apps run fine yeah!

its strange cuz even the hello-world code from the visual studio "guide" only runs at 8-9fps >.<

edit: seems it fixed itself after i got visual studio closed for a while...
will keep an eye on my system to see what causes this...

Edit: Seems like the Problem comes from my stone-aged TV-capture card and its semi-working drivers...

24
Using avast, back then i used avira... disabling avast doesn't make any difference...

nope of course not using any software that claims to make the system faster...

25
back then: 1.6
now: 2.0

back then: nvida gpu
now: amd gpu

26
yeah exactly like that
nope

in win7 shutting of aero before running the application seemed to do the trick, making it working again for a 1 time usage... after that i had to reenable and disable aero again...

now in win8 i dont have this option of a workaround :(

27
haha yeah of course! everything works perfectly ;)
if i restart the computer sfml works like a charm too, but i dont want to always restart my pc after i debugged 3-4 times...

28
Have to open up my old thread again, sorry...
Having the same Problem again... now, with windows 8, wich hasn't got aero... and a fresh new top-notch pc...

I dont know how to work around it now, or how i could fix it...
could this be because of an windows-service i shut off?

any halp would be greatly appreciated

29
Graphics / qimage to sf::image conversion
« on: May 26, 2011, 02:23:32 pm »
woot? why i didn't find the qAlpha function in the doc? :O

30
Graphics / qimage to sf::image conversion
« on: May 25, 2011, 11:16:58 pm »
I only tested it with an black/transparent image....

will try...

edit: your right... :/

edit2: OpenGLWidget conversion keeps the colours but flips the y of my image xD  not that big deal, but kinda sucks :D

Pages: 1 [2] 3
anything