mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 17:20:04 +00:00
Shrinking location crosshairs to 24x24, rotating 45 degrees
This commit is contained in:
parent
cf0b268822
commit
7057f14b22
5 changed files with 9 additions and 6 deletions
BIN
scwx-qt/res/textures/images/crosshairs-24.png
Normal file
BIN
scwx-qt/res/textures/images/crosshairs-24.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1 KiB |
|
|
@ -59,6 +59,6 @@
|
||||||
<file>res/palettes/wct/ZDR.pal</file>
|
<file>res/palettes/wct/ZDR.pal</file>
|
||||||
<file>res/textures/lines/default-1x7.png</file>
|
<file>res/textures/lines/default-1x7.png</file>
|
||||||
<file>res/textures/lines/test-pattern.png</file>
|
<file>res/textures/lines/test-pattern.png</file>
|
||||||
<file>res/textures/images/crosshairs-32.png</file>
|
<file>res/textures/images/crosshairs-24.png</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
|
|
||||||
|
|
@ -41,7 +41,7 @@ public:
|
||||||
activeBoxInner_ {std::make_shared<gl::draw::Rectangle>(context)},
|
activeBoxInner_ {std::make_shared<gl::draw::Rectangle>(context)},
|
||||||
icons_ {std::make_shared<gl::draw::GeoIcons>(context)},
|
icons_ {std::make_shared<gl::draw::GeoIcons>(context)},
|
||||||
locationIconName_ {
|
locationIconName_ {
|
||||||
types::GetTextureName(types::ImageTexture::Crosshairs32)}
|
types::GetTextureName(types::ImageTexture::Crosshairs24)}
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
~OverlayLayerImpl() = default;
|
~OverlayLayerImpl() = default;
|
||||||
|
|
@ -101,6 +101,8 @@ void OverlayLayer::Initialize()
|
||||||
p->locationIcon_ = p->icons_->AddIcon();
|
p->locationIcon_ = p->icons_->AddIcon();
|
||||||
gl::draw::GeoIcons::SetIconTexture(
|
gl::draw::GeoIcons::SetIconTexture(
|
||||||
p->locationIcon_, p->locationIconName_, 0);
|
p->locationIcon_, p->locationIconName_, 0);
|
||||||
|
gl::draw::GeoIcons::SetIconAngle(p->locationIcon_,
|
||||||
|
units::angle::degrees<double> {45.0});
|
||||||
gl::draw::GeoIcons::SetIconLocation(
|
gl::draw::GeoIcons::SetIconLocation(
|
||||||
p->locationIcon_, coordinate.latitude(), coordinate.longitude());
|
p->locationIcon_, coordinate.latitude(), coordinate.longitude());
|
||||||
p->icons_->FinishIcons();
|
p->icons_->FinishIcons();
|
||||||
|
|
|
||||||
|
|
@ -16,8 +16,8 @@ struct TextureInfo
|
||||||
};
|
};
|
||||||
|
|
||||||
static const std::unordered_map<ImageTexture, TextureInfo> imageTextureInfo_ {
|
static const std::unordered_map<ImageTexture, TextureInfo> imageTextureInfo_ {
|
||||||
{ImageTexture::Crosshairs32,
|
{ImageTexture::Crosshairs24,
|
||||||
{"images/crosshairs-32", ":/res/textures/images/crosshairs-32.png"}}};
|
{"images/crosshairs-24", ":/res/textures/images/crosshairs-24.png"}}};
|
||||||
|
|
||||||
static const std::unordered_map<LineTexture, TextureInfo> lineTextureInfo_ {
|
static const std::unordered_map<LineTexture, TextureInfo> lineTextureInfo_ {
|
||||||
{LineTexture::Default1x7,
|
{LineTexture::Default1x7,
|
||||||
|
|
|
||||||
|
|
@ -13,11 +13,12 @@ namespace types
|
||||||
|
|
||||||
enum class ImageTexture
|
enum class ImageTexture
|
||||||
{
|
{
|
||||||
|
Crosshairs24,
|
||||||
Crosshairs32
|
Crosshairs32
|
||||||
};
|
};
|
||||||
typedef scwx::util::Iterator<ImageTexture,
|
typedef scwx::util::Iterator<ImageTexture,
|
||||||
ImageTexture::Crosshairs32,
|
ImageTexture::Crosshairs24,
|
||||||
ImageTexture::Crosshairs32>
|
ImageTexture::Crosshairs24>
|
||||||
ImageTextureIterator;
|
ImageTextureIterator;
|
||||||
|
|
||||||
enum class LineTexture
|
enum class LineTexture
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue