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 - na.mkv

Pages: [1]
1
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 18, 2024, 11:05:43 am »
All began working ok, except, again, for this code snippet:

void Actions::load_main_menu_music(Music * music) {
    if (!music->openFromFile("../Audio/Music/MainTheme.mp3")) {
        throw std::runtime_error("Couldn't open the music file.");
    }
}


I get the error when I execute this command in the terminal: cmake -S . -B build ; cmake --build build --config Release


Error:
Actions.obj : error LNK2019: unresolved external symbol "public: bool __cdecl sf::Music::openFromFile(class std::basic_string<char,struct std::char_traits<char
>,class std::allocator<char> > const &)" (?openFromFile@Music@sf@@QEAA_NAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) referenced in func
tion "void __cdecl Actions::load_main_menu_music(class sf::Music *)" (?load_main_menu_music@Actions@@YAXPEAVMusic@sf@@@Z) [C:\Users\rcybe\CLionProjects\Asteroi
dBelt\build\AsteroidBelt.vcxproj]
C:\Users\rcybe\CLionProjects\AsteroidBelt\build\bin\Release\AsteroidBelt.exe : fatal error LNK1120: 1 unresolved externals [C:\Users\rcybe\CLionProjects\Astero
idBelt\build\AsteroidBelt.vcxproj]


2
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 17, 2024, 03:31:18 pm »
I have carefully followed the instructions and in the end I got this:


PS C:\Users\rcybe\CLionProjects\AsteroidBelt> cmake --build build --config Release
MSBuild version 17.8.3+195e7f5a3 for .NET Framework
MSBUILD : error MSB1009: Project file does not exist.
Switch: ALL_BUILD.vcxproj
PS C:\Users\rcybe\CLionProjects\AsteroidBelt> cmake -S . -B build                 
-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.22631.
-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.22631.
CMake Error at C:/Program Files/CMake/share/cmake-3.28/Modules/ExternalProject.cmake:2911 (message):
  error: could not find git for clone of sfml-populate
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.28/Modules/ExternalProject.cmake:4422 (_ep_add_download_command)
  CMakeLists.txt:29 (ExternalProject_Add)


-- Configuring incomplete, errors occurred!

CMake Error at C:/Program Files/CMake/share/cmake-3.28/Modules/FetchContent.cmake:1667 (message):
  CMake step for sfml failed: 1
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.28/Modules/FetchContent.cmake:1819:EVAL:2 (__FetchContent_directPopulate)
  C:/Program Files/CMake/share/cmake-3.28/Modules/FetchContent.cmake:1819 (cmake_language)
  C:/Program Files/CMake/share/cmake-3.28/Modules/FetchContent.cmake:2033 (FetchContent_Populate)
  CMakeLists.txt:11 (FetchContent_MakeAvailable)


-- Configuring incomplete, errors occurred!


To be honest, I am new in Windows; 70% of my time I was working in Linux or MacOS. It is just now I decided completely switch to Windows.

3
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 17, 2024, 02:59:01 pm »
IIRC 0xC0000135 just means that you're missing some DLL.
If you double click the executable in explorer, it should tell you which DLL exactly is missing.

Most likely, you'll have to copy the SFML DLLs next to your executable.

I ran the executable, it says: "The code execution cannot proceed because libstdc++-6.dll was not found. Reinstalling the program may fix this problem."

The missing files:
libstdc++-6.dll
openal32.dll
libgcc_s_dw2-1.dll

4
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 17, 2024, 02:42:36 pm »
Copied and pasted the cmake. Have the problem:

"C:\Program Files\JetBrains\CLion 2023.3.2\bin\cmake\win\x64\bin\cmake.exe" -DCMAKE_BUILD_TYPE=Debug "-DCMAKE_MAKE_PROGRAM=C:/Program Files/JetBrains/CLion 2023.3.2/bin/ninja/win/x64/ninja.exe" -G Ninja -S C:\Users\rcybe\CLionProjects\AsteroidBelt -B C:\Users\rcybe\CLionProjects\AsteroidBelt\cmake-build-debug
CMake Error at C:/Program Files/JetBrains/CLion 2023.3.2/bin/cmake/win/x64/share/cmake-3.27/Modules/ExternalProject.cmake:2851 (message):
  error: could not find git for clone of sfml-populate
Call Stack (most recent call first):
  C:/Program Files/JetBrains/CLion 2023.3.2/bin/cmake/win/x64/share/cmake-3.27/Modules/ExternalProject.cmake:4345 (_ep_add_download_command)
  CMakeLists.txt:29 (ExternalProject_Add)

5
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 17, 2024, 02:20:18 pm »
Assume I copy all DLLs to the project directory. What else? How should I re-write cmake? How to make the snippet

void Actions::load_main_menu_music(Music * music) {
    if (!music->openFromFile("../Audio/Music/MainTheme.mp3")) {
        throw std::runtime_error("Couldn't open the music file.");
    }
}

not to cause the issue? Again, the error appears before even the program runs.

6
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 17, 2024, 01:22:08 pm »
The function is not called anywhere. It breaks even before the execution line reaches int main().
It breaks somewhere between the compilation and run.

7
System / Re: Process finished with exit code -1073741515 (0xC0000135)
« on: January 17, 2024, 07:11:44 am »
Also I have the same issue when I try to compile a file with this code snippet.


void Actions::load_main_menu_music(Music * music) {
    if (!music->openFromFile("../Audio/Music/MainTheme.mp3")) {
        throw std::runtime_error("Couldn't open the music file.");
    }
}

Do somebody have any ideas how to fix this?

8
System / Process finished with exit code -1073741515 (0xC0000135)
« on: January 16, 2024, 01:57:08 pm »
Good day. I have a problem with SFML on Windows 11.

I have the same issue when using SFML for 32 and 64 bit systems.

Here I am attaching the screenshots with the code for cmake and main.cpp.

I really have no idea what is wrong here. It worked fine on Unix, but I have a struggle with win now. I seek help.

Whenever I try to run the program, I get the error message: "Process finished with exit code -1073741515 (0xC0000135)".

I have downloaded the SFML and mingw, and copied them to "C:/" directory

9
Make sure the font is valid.

And what do you mean by "valid" exactly?

10
I just copied the Arial.ttf that was built-in by Apple itself. It has to be ok

11
Still doesn't help.


12
Graphics / Rendering in a separate thread in OS X
« on: December 30, 2023, 09:10:11 am »
Hello. I was told by ChatGPT that it is very bad idea to make a separate thread for rendering and leave the main one for the events.
I also use MacOS which is double bad idea (as ChatGPT says). Is this true?

Pages: [1]