TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #164 · 14 окт.

🙄Разминка для ума! Треугольник Серпинского, интересная фигура которую построить достаточно просто. Алгоритм такой: 1. создаём любые 3 точки на плоскости 2. из этих точек случайно выбираем любую, как начальную 3. случайно выбираем любую точку из этих же трёх точек как цель 4. перемещаемся в сторону цели на половину расстояния 5. повторяем бесконечно с пункта 3 Если сделать достаточно много итераций то вырисовывается интересная фигура. Треугольник, в который вписаны более мелкие треугольники. Это самый настоящий фрактал! Я собрал пример построения такой фигуры на базе Qt. 🌎 Код можно посмотреть здесь. С помощью paintEvent я рисую точки по озвученному алгоритму. Каждые 10 секунд либо по клику на виджете строится следующий треугольник. Особенности примера: 🔸 Атрибут Qt.WA_OpaquePaintEvent позволяет сохранить то, что было нарисовано в прошлой итерации. Таким образом мы видим постепенное наполнение точек а не мелькающую одну точку. 🔸QTimer позволяет создавать отложенные вызовы один раз или с повторением через интервал. 🔸QColor.fromHsv() позволяет создать рандомный но предсказуемый цвет с помощью HSV схемы. Не слишком светлый и не слишком тёмный но всегда с разный. Рандомизации подвергается только смещение по цветовому кругу (Hue), яркость (Value) и насыщенность (Saturation) можно контролировать отдельно в своих пределах или оставить статичными. Обычный рандом цвета по RGB не даёт такой предсказуемый результат. 🔸 Каждый новый цикл с новым треугольником предварительно затемняет предыдущие через этот вызов painter.fillRect(rec, QColor(0, 0, 0, 100)) То есть полупрозрачный цвет. Таким образом, чем старше треугольник, тем он темней. Если сделать виджет фулскрин, то у нас получится некий ScreenSaver))) 🔸 Да, я знаю, что рисование в Qt не самый лучший способ сделать этот пример) Скорее всего самый НЕподходящий. Попробуйте сделать тоже самое но другими средствами. #qt#source#tricks

Резултати

Пронајдени 3 слични објави

Пребарај: #hackerspace

当前筛选 #hackerspace清除筛选
Medet Turin 🫆

@allsafekz · Post #731 · 20.05.2025 г., 09:37

https://lnkd.in/e25HNh7A Alhamdulillah, I finished writing this book in few days. I wrote this book to help my friends: Nurkhankyzy Aiya, Acute myeloid leukemia (AML). and all those children who are fighting for their lives. Why is the book called that? AIYA MMD - means Attack and Introduction or (Android and IOS), start Your Adventure in Mobile Malware Development. also AIYA means AIYA Nurkhankyzy. I will be very happy if this book helps at least one person to gain knowledge and learn the science of cybersecurity. The book is mostly practice oriented. Of course the book is not as big as my previous works, this is because firstly I needed to urgently start a fundraising campaign for the Aiya and secondly many things remain confidential (NDA) Mobile malware - it's a constantly evolving battlefield. What you learned here is just the beginning. Tools change, defenses adapt, but the mindset stays the same: think like the adversary to build stronger defenses. This book is dedicated to my wife, Laura, and my children, Yerzhan and Munira. I would like to express my deep gratitude to my friends and colleagues. Special thanks to #Russian#hacking#community, Medet Turin 2600.kz, BlackIce #hackerspace from Almaty (Kazakhstan) and my friends from Middle East countries: Kingdom of Bahrain, Kingdom of Saudi Arabia, UAE. All examples are practical cases for educational and research purposes only. Book design by: Muhammad Patel twitter: https://x.com/cocomelonckz/status/1924724518951457229 #hacking#mobile#malware#research#book#programming#android#ios#rat#spyware

Чёрный Лёд

@blackicehackerspace · Post #107 · 20.05.2025 г., 09:38

https://lnkd.in/e25HNh7A Alhamdulillah, I finished writing this book in few days. I wrote this book to help my friends: Nurkhankyzy Aiya, Acute myeloid leukemia (AML). and all those children who are fighting for their lives. Why is the book called that? AIYA MMD - means Attack and Introduction or (Android and IOS), start Your Adventure in Mobile Malware Development. also AIYA means AIYA Nurkhankyzy. I will be very happy if this book helps at least one person to gain knowledge and learn the science of cybersecurity. The book is mostly practice oriented. Of course the book is not as big as my previous works, this is because firstly I needed to urgently start a fundraising campaign for the Aiya and secondly many things remain confidential (NDA) Mobile malware - it's a constantly evolving battlefield. What you learned here is just the beginning. Tools change, defenses adapt, but the mindset stays the same: think like the adversary to build stronger defenses. This book is dedicated to my wife, Laura, and my children, Yerzhan and Munira. I would like to express my deep gratitude to my friends and colleagues. Special thanks to #Russian#hacking#community, Medet Turin 2600.kz, BlackIce #hackerspace from Almaty (Kazakhstan) and my friends from Middle East countries: Kingdom of Bahrain, Kingdom of Saudi Arabia, UAE. All examples are practical cases for educational and research purposes only. Book design by: Muhammad Patel twitter: https://x.com/cocomelonckz/status/1924724518951457229 #hacking#mobile#malware#research#book#programming#android#ios#rat#spyware