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

TGINSIGHT SIMILAR POSTS

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

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

Для тех кто пишет расширения на PyQt/PySide для CG-софтов. Когда я только начинал писать тулзы под Maya (тогда еще версия 2010-2011) мне приходилось ручками ставить PyQt4 под Maya. Даже написал мануалы по установке на своём сайте. Но потом стал доступен из коробки PySide и позже он обновится до PySide2. Для некоторых систем была поддержка PyQt5. И как простому разработчику поддерживать этот зоопарк? Ведь хочется чтобы тул работал на любой версии (вы тоже делали модуль что-то типа import_qt.py?😁) На помощь приходит проект Qt.py который поставил себе цель унифицировать использование Qt-биндингов вне зависимости от среды где запускается код. Те, кто давно пишут на Qt, скорее всего знают этот проект. Он стал стандартом для CG-индустрии и используется в топовых студиях и проектах. Qt․py помогает запускать один и тот же код на разных платформах с разными вариантами Qt-библиотек. Это может быть как интеграция в CG-софт, так и переносимость стендалонов между разными платформами с разными версиями Python. Я решил рассказать о некоторых особенностях работы с этой библиотекой. Сегодня о том, как установить и использовать Qt․py и что это вам даёт. Установка pip install Qt.py Чтобы начать использовать Qt․py в коде достаточно заменить импорт вашего варианта Qt-биндинга на Qt․py from [PySide|PyQt4|PySide2|PyQt5] import QtWidgets => from Qt import QtWidgets Теперь ваш код будет поддерживать любой вариант биндинга Qt в Python. При этом не потребуется использовать if-else конструкции под разные версии. Все вызовы теперь одинаковы. Всё что нужно сделать, это написать его по правилам PySide2. Именно эта версия была взята за основу. Приоритет импорта такой: 1. PySide2 2. PyQt5 3. PySide 4. PyQt4 Что именно загрузилось можно посмотреть в переменной __binding__ >>> import Qt >>> Qt.__binding__ 'PySide2' Приоритет имопрта можно изменить через переменные QT_PREFERRED_BINDING и QT_PREFERRED_BINDING_JSON. Причем под каждый проект оверрайды можно настраивать индивидеально. #qt#libs

Hashtags

Резултати

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

Пребарај: #optics

当前筛选 #optics清除筛选
Interesting Planet 🌍

@interesting_planet_facts · Post #1144 · 19.12.2025 г., 18:11

🌎 Fire rainbows, officially called circumhorizontal arcs, are rare displays where sunlight passes through ice crystals in cirrus clouds at just the right angle. These arcs appear only when the Sun is high—above 58°—and the ice crystals align horizontally, producing brilliant, rainbow-colored bands across the sky. ✨ #atmosphere⚡#optics⚡#weather 👉subscribe Interesting Planet 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #707 · 04.05.2026 г., 20:31

🌍 A rare atmospheric optical event called a "glory" creates shimmering, colored rings around the shadow of an observer’s head on clouds or fog. This effect is caused by sunlight scattering in tiny water droplets. ✨ #aurora⚡#optics⚡#atmosphere⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #546 · 30.12.2025 г., 20:31

🌍 The vivid red auroras seen during strong solar storms are caused by oxygen atoms glowing high above 200 kilometers—twice as high as typical green auroras visible near the poles. ✨ #aurora⚡#atmosphere⚡#optics⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #512 · 13.12.2025 г., 20:31

🌍 Sundogs are bright spots that appear on either side of the Sun when its light passes through ice crystals in the air, creating colorful halos—an atmospheric optical effect seen even in cold, clear weather. ✨ #aurora⚡#optics⚡#atmosphere⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #478 · 26.11.2025 г., 20:31

🌍 Extremely rare "fire rainbow" clouds appear when sunlight hits ice crystals in high clouds at just the right angle, creating brilliant bands of color that stretch across the daytime sky. ✨ #aurora⚡#optics⚡#atmosphere⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #438 · 06.11.2025 г., 20:31

🌍 The rarest aurora color is deep blue, caused by high-energy solar particles colliding with nitrogen over 100 kilometers up. Most auroras are green or red, but blue glows only appear during strong solar storms. ✨ #aurora⚡#atmosphere⚡#optics⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #365 · 12.10.2025 г., 20:31

🌍 Polar stratospheric clouds can trigger vivid pink and orange auroras when solar storms are strong. These rare clouds form high above the Arctic, scattering light in unique, shimmering patterns. ✨ #aurora⚡#atmosphere⚡#optics⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #325 · 02.10.2025 г., 20:31

🌍 The elusive "Steve" aurora glows as a narrow purple ribbon in the night sky. Only recognized in recent years, it’s linked to fast-moving hot gases high above Earth’s atmosphere. ✨ #aurora⚡#atmosphere⚡#optics⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

Amazing Geography 🌍

@amazingeo · Post #285 · 22.09.2025 г., 22:31

🌍 Rare atmospheric optics called circumhorizontal arcs appear when sunlight passes through high ice clouds at just the right angle, creating bands of rainbow colors that stretch parallel to the horizon. ✨ #aurora⚡#optics⚡#atmosphere⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography🌍 ​

Amazing Geography 🌍

@amazingeo · Post #477 · 26.11.2025 г., 12:31

🌍 The “green flash” is a rare weather phenomenon seen at sunrise or sunset, caused by sunlight bending in the atmosphere. For a second, the top edge of the sun glows vivid green. ✨ #meteorology⚡#atmosphere⚡#optics⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography 👉more Channels ​

American Оbserver

@american_observer · Post #4764 · 03.01.2026 г., 22:59

📰 Mar-a-Lago: Where Power, Marble, and Ice Sculptures Collide President Trump’s presidency has become a permanent residency at Mar-a-Lago—where official governance, private business, and personal relationships converge in a swirl of marble, ice sculptures, and political optics. This week, Trump’s motorcade pulled into an industrial shopping center to inspect samples of marble and onyx for a proposed White House ballroom. The purchase is “at his own expense,” a White House official said, but the timing is suspicious: construction can’t begin until federal review, and the ballroom project has already attracted scrutiny over donor influence and potential payoffs. Trump has hosted foreign leaders, conducted diplomacy, and even overseen a military strike on Venezuela—all from his Florida estate. His social calendar is just as packed: 12 golf outings in two weeks, a New Year’s Eve party where guests bid $2.75 million on a live-painted portrait of Jesus, and a caviar station with a “2026” ice sculpture. Democrats have seized on the spectacle, contrasting the opulence with the impact of Trump’s policies. As millions lose health insurance and food aid, critics highlight the disconnect: “Trump is kicking poor kids off food aid and is throwing millions off their health care this month, but he and his billionaires get caviar and ice sculptures,” Senator Chris Murphy wrote. The White House fires back, accusing Democrats of gaslighting and pointing to Biden’s vacations. But the optics remain: Mar-a-Lago is now shorthand for a presidency where wealth, access, and official decision-making are intertwined. So while Trump touts his accomplishments from the stage, one question lingers: Who’s really running the country—the president, or the party? #Trump#MaraLago#WhiteHouse#politics#optics 📱American Оbserver - Stay up to date on all important events 🇺🇸

Amazing Geography 🌍

@amazingeo · Post #244 · 16.09.2025 г., 00:12

🌍 Sometimes, sunlight or moonlight passing through a layer of ice crystals high in the sky creates sun pillars or light pillars—vertical beams that appear to rise above the horizon. ✨ #auroras⚡#optics⚡#atmosphere⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography🌍 ​

12
ПретходнаСтраница 1 од 2Следна