Гость » 09 мар 2024, 22:25
Последнее сообщение Гость «
Гость »
Я создавал дисплей, управляемый через Bluetooth, используя Qt и raspberrypi. На raspberrypi будет работать служба Bluetooth, и когда я подключусь к BluetoothServer. Пользователь может выбрать либо отображение сообщения, либо загрузку и отображение...
Гость » 09 мар 2024, 22:22
Последнее сообщение Гость «
Гость »
У меня проблема с потоками ввода-вывода в C++. Мне нужно написать программу, которая считывает данные из файла и записывает их в другой файл. Команда в CMD должна выглядеть так: «программа файл2». Имена файлов должны быть предоставлены пользователем...
Гость » 09 мар 2024, 22:19
Последнее сообщение Гость «
Гость »
Можно ли в C++ выполнять перечисление (либо во время выполнения, либо во время компиляции (предпочтительно)) и вызывать функции/генерировать код для каждой итерации?
Гость » 09 мар 2024, 22:17
Последнее сообщение Гость «
Гость »
В «Букваре C++» Стэнли Липпмана на странице 234 упоминается, что
Обычно объявлять функцию локально — плохая идея. Однако
чтобы объяснить, как область видимости взаимодействует с перегрузкой, мы нарушим эту
практику и будем использовать объявления...
Гость » 09 мар 2024, 22:08
Последнее сообщение Гость «
Гость »
Рассмотрим пример ниже. Предположим, что barrier is initialized to 0.
There is one producer thread and two consumer threads that constantly check barrier . If the barrier is set, they decrease runcnt . The producer thread waits for runcnt to reach...
Гость » 09 мар 2024, 22:06
Последнее сообщение Гость «
Гость »
Я знаю это std::shared_ptr et al emulate covariance by having templated constructors.
But let's say I have an abstract base class that's a simple accessor:
template
class Reader {
public:
virtual const T& Get() const = 0;
};
Гость » 09 мар 2024, 21:55
Последнее сообщение Гость «
Гость »
If I have an enum that does not assign numbers to the enumerations, will its ordinal value be 0? For example:
enum enumeration { ZERO,
ONE,
TWO,
THREE,
FOUR,
FIVE,
SIX,
SEVEN,
EIGHT,
NINE };
I've been able to find a post citing that the C99...
Гость » 09 мар 2024, 21:54
Последнее сообщение Гость «
Гость »
I've been experimenting with the enum class feature of C++ and successfully got the ++ operator to overload as follows:
enum class counter_t : uint8_t {VAL1 = 0, VAL2, VAL3, VAL4, END};
Гость » 09 мар 2024, 21:42
Последнее сообщение Гость «
Гость »
I have two classes: a Parent class and a Child class (inheriting from the Parent class). I would like to know if it is possible to cast/transform a Child** to a Parent** with reinterpret_cast or something else. Is such a thing possible?
Below is a...
Гость » 09 мар 2024, 21:41
Последнее сообщение Гость «
Гость »
I have a problem with I/O streams in c++. I have to write a program which read data from file and writes it into another file. Command in CMD should be like: program file2 . The names of the files should be provided by the user (could be...
Гость » 09 мар 2024, 21:30
Последнее сообщение Гость «
Гость »
I'm working on my PHD and need an (well known and tested) C/C++ library that gives an exact solution for the TSP problem to compare with my heuristics.
Гость » 09 мар 2024, 21:28
Последнее сообщение Гость «
Гость »
I've been developping my first flutter app using flutlab and have recently set things up in vscode. Everything works fine in the web emulator but when I try to run for linux I get the following error:
Launching lib/main.dart on Linux in debug...
Гость » 09 мар 2024, 21:21
Последнее сообщение Гость «
Гость »
I'm new in the raspbian bios and programming language, I have problem with receiving data from the raspberry pi 4 uart (ttyS0). I have ADC converter of course, which returns me hexadecimal string with data. The Przemytnik class is for connecting c++...
Гость » 09 мар 2024, 21:17
Последнее сообщение Гость «
Гость »
I’d like to write some native code in C or C++ to be used with Swift on iOS. This code would mainly be invoked from Swift but would also need to callback to Swift as well, like shown in this diagram:
Гость » 09 мар 2024, 21:16
Последнее сообщение Гость «
Гость »
I would like to have objects add a pointer pointing to themselves into a map which is a member of another class.
Here is what I have so far:
// entitymanager.h
// Inside the public part of the EntityManager class
std::map AllMapEntities;
Гость » 09 мар 2024, 21:15
Последнее сообщение Гость «
Гость »
I was building a bluetooth controlled display using Qt and raspberrypi.The raspberrypi will have a bluetooth service running on it and when I connect to the BluetoothServer. The user can choose to either a display a message or upload and display an...
Гость » 09 мар 2024, 21:02
Последнее сообщение Гость «
Гость »
I am using C++ Winforms. So I have a Control in my form.
Now what I want to do is something like this to check if a control is a TextBox :
if (control is TextBox)
{
// ...
}
In C# you can do the above I believe. But how can I do the same in C++...
Гость » 09 мар 2024, 20:33
Последнее сообщение Гость «
Гость »
I am trying to port a C++ library with a C calling convention to C#.
The project is at
I am trying to port the sample C++ application and use the .DLL from the Lepcc C++ project.
I am getting an access violation (memory corrupt) when the...
Гость » 09 мар 2024, 20:21
Последнее сообщение Гость «
Гость »
I have a Qt application which uses pybind to embed python plugins providing some kind of handlers. From what I have read online gluing the event loops is nearly impossible. Now I wonder if it is possible to run an asyncio event loop in a c++...
Гость » 09 мар 2024, 20:18
Последнее сообщение Гость «
Гость »
I want to inherit from a template class with a type defined in the derived class. I dont want to use composition because if I do so, I have to give public access to the vector or write some methods for each object in order to interact with the...
Гость » 09 мар 2024, 20:15
Последнее сообщение Гость «
Гость »
please ignore my bad coding practice i cant for the life of me figure out how classes in C work nevermind in visual studio as before this i only coded in java in eclipse XD
but here is my messy code
#include
#include
#include
#include
#include...
Гость » 09 мар 2024, 20:08
Последнее сообщение Гость «
Гость »
I'm trying to optimize my 3D rendering OpenCL code. Currently, I render a 3D triangle by dividing its bounding box into 2x2 tiles and doing necessary computations for each pixel inside the tile. This turned out to be slightly faster than giving each...
Вы можете начинать темы Вы можете отвечать на сообщения Вы не можете редактировать свои сообщения Вы не можете удалять свои сообщения Вы можете добавлять вложения