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

Pages: [1] 2
1
Graphics / Re: I tried to build a particle system with VertexArray
« on: March 10, 2025, 04:14:13 pm »
Or I should just use Sprite lists and draw them particle by particle?

2
Graphics / I tried to build a particle system with VertexArray
« on: March 10, 2025, 04:05:58 pm »
The particle class is inherited from Sprite.
It's terribly laggy when there's over 10,000 particles moving at the same time.
It's very slow when changing those vertexes' position in function Update().

Is there any solution? Thanks for your time.

3
I use SFML 3.0. The repository of the link you gave me is abandoned long ago and there's no WindowHandle.

4
I can't bind WindowHandle.

error: invalid use of incomplete type 'struct HWND__'

I know it's from Windows API, but #include <Windows.h> didn't work either.

5
General discussions / Re: Can vlc work on SFML window?
« on: March 16, 2024, 07:18:06 pm »
I've no idea how VLC can be integrated into other applications.

Have you followed the Getting Started section: https://sfemovie.yalir.org/latest/start.php

I had trouble building sfeMovies. That's why I had to look for some libraries else.

6
General discussions / Can vlc work on SFML window?
« on: March 15, 2024, 07:24:36 pm »
I tried mciSendString, but it created a new window to play the video.
Besides, I don't quite understand how to install sfeMovies in my project(CMake, CLion)

7
General discussions / Something about playing video.
« on: March 07, 2024, 04:34:05 pm »
Hi, I want to play videos on SFML window, but I don't know a proper way.
Does anyone know a library that fits to SFML and easy to use?

8
General / problem with mingw
« on: November 03, 2023, 07:34:22 pm »
Hi, I'm using CLion with mingw64.

My exe needs libgcc_s_seh-1.dll, libstdc++-6.dll and libwinpthread-1.dll.

I was wondering how can I statically link mingw?

9
The dll that SFML project needs is kind of large. openal32, sfml-audio-d-2, sfml-graphics-d-2, sfml-network-d-2, sfml-system-d-2, sfml-window-d-2, six dlls are totally 13.7 MB.
Besides, font file is approximately 20MB, can sf::Font load from system fonts?
I'm using CLion, by the way.

10
General / Problem with dll
« on: October 13, 2023, 09:33:40 am »
Hi to all,
I configured SFML in CLion on my computer through the tutorial, but the generated program shows that the dll is missing on other computers. What should I do?

11
Graphics / Re: Issue with display of pictures
« on: October 04, 2023, 07:06:40 am »
In your setSprite function, you make a texture and assign it to the sprite. But the texture is just a local variable, so when the function ends the texture is deleted and the sprite now contains an invalid pointer to where the texture used to be.
Textures need to have at least the same lifetime as a sprite, since sprites don't make a copy of the texture.
Thank you. Problem solved. :D

12
Graphics / Issue with display of pictures
« on: October 03, 2023, 09:29:26 pm »
Dear Community,
I don't know how to express this problem explicitly..
I set a class like this:
class Image {
public:
void init();
void show();
private:
Sprite spr;
};
and a vector like vector <Image*> pics;
init() could initialize spr and pics.push_back(this) and show() is just window.draw(spr); and window.display();.
Here comes the problem. When it comes to pics[0]->show();, the screen becomes whole white.
I'm sure the problem is from the sentence pics[0]->show();, because when I delete it and put show() at the bottom of init(), everything works fine.
I hope you can understand what I was saying according to the attaching sceenshots, because my expression was really poor.

Best regards.

13
Graphics / Re: Issue with cache of pictures
« on: October 02, 2023, 06:46:50 am »
Sorry guys. I found out that it was the loop's fault. Problem solved.

14
Graphics / Re: Issue with cache of pictures
« on: October 02, 2023, 06:38:14 am »
I just tested your first version, it works fine. (I usually use texture pointers in my resource system map, but textures work too)
Are you sure that's the part causing the crash?
I wrote this and the program crashed here:
textureCache[string("animation\\") + fileinfo.name].loadFromFile(string("..\\graphics\\animation\\") + fileinfo.name);

15
Graphics / Re: Issue with cache of pictures
« on: October 01, 2023, 10:06:26 pm »
That's really confusing. I'm sure the file is existed.😥

Pages: [1] 2
anything