Page 1 of 2

Standard camera mode.

Posted: 18 Dec 2009, 17:08
by Spawn_Retard
I'd like to suggest their be an easy way to rotate the camera angle of a map by 90 degrees with a short key when playing with the standard camera mode, it would make maps more interesting to me personally as i would be able to see them from angles that i normally would never see without speccing and using other camera modes.


tl;dr spice maps up by making the default camera turn by 90 degrees by using a keybind such as ctrl [ or ] for instances.

Re: Standard camera mode.

Posted: 18 Dec 2009, 17:16
by Regret

Re: Standard camera mode.

Posted: 19 Dec 2009, 12:27
by Spawn_Retard
could it be a feature though, instead of a lua and a meta key?

Re: Standard camera mode.

Posted: 19 Dec 2009, 13:38
by Regret
Spawn_Retard wrote:could it be a feature though, instead of a lua and a meta key?
All cameras should eventually be moved to lua.

Re: Standard camera mode.

Posted: 19 Dec 2009, 15:36
by Google_Frog
Regret wrote:
Spawn_Retard wrote:could it be a feature though, instead of a lua and a meta key?
All cameras should eventually be moved to lua.
And what do users see if luaui crashes?

Re: Standard camera mode.

Posted: 19 Dec 2009, 18:53
by Regret
Google_Frog wrote:And what do users see if luaui crashes?
One default engine camera.

Re: Standard camera mode.

Posted: 20 Dec 2009, 19:25
by Tribulex
Regret wrote:
Google_Frog wrote:And what do users see if luaui crashes?
One default engine camera.
BINGO

Re: Standard camera mode.

Posted: 21 Dec 2009, 00:01
by srapop
i think the rotating would be very useful.It might be even added to TA-style overview camera because rotation is the only thing taht this cam mode lacks.
That could be the "default engine camera".

Re: Standard camera mode.

Posted: 21 Dec 2009, 02:57
by BrainDamage
Regret wrote:
Spawn_Retard wrote:could it be a feature though, instead of a lua and a meta key?
All cameras should eventually be moved to lua.
http://springrts.com/phpbb/viewtopic.ph ... 67#p397067

hypocrisy much?
let me paraphrase it here, changes marked italic
Regret wrote:a) having new widget is good
b) losing a feature from engine for no reason (cameras do not prohibit anything while being an engine feature) despite having a widget replacement is bad
c) having both the widget AND the current engine feature is better than having just a widget

Re: Standard camera mode.

Posted: 21 Dec 2009, 08:05
by 1v0ry_k1ng
engine fixes are always better than widgets, because widgets lose compatability between spring versions

Re: Standard camera mode.

Posted: 21 Dec 2009, 09:46
by Regret
Brain Damage wrote:
Regret wrote:
Spawn_Retard wrote:could it be a feature though, instead of a lua and a meta key?
All cameras should eventually be moved to lua.
http://springrts.com/phpbb/viewtopic.ph ... 67#p397067

hypocrisy much?
let me paraphrase it here, changes marked italic
Regret wrote:a) having new widget is good
b) losing a feature from engine for no reason (cameras do not prohibit anything while being an engine feature) despite having a widget replacement is bad
c) having both the widget AND the current engine feature is better than having just a widget
no u

Changing words is very mature, even if you point out what you changed, it deforms the original point which was specific to the thread.

This is completely different as current camera system conflicts with additional lua cameras, so one has to go or a new system has to be made for both to function together.

Re: Standard camera mode.

Posted: 21 Dec 2009, 14:59
by Pxtl
My request: engine support for rotating the minimap. Rotating the minimap in Lua means re-implementing a farktonne UI stuff, the kind of thing that will break between versions. With rotatable minimap, the rotatable cameras will be much more usable.

Re: Standard camera mode.

Posted: 21 Dec 2009, 15:32
by SirMaverick
Pxtl wrote:My request: engine support for rotating the minimap. Rotating the minimap in Lua means re-implementing a farktonne UI stuff, the kind of thing that will break between versions. With rotatable minimap, the rotatable cameras will be much more usable.
+1

Even /viewtaflip does not flip minimap.

Re: Standard camera mode.

Posted: 21 Dec 2009, 18:07
by srapop
Pxtl wrote:My request: engine support for rotating the minimap. Rotating the minimap in Lua means re-implementing a farktonne UI stuff, the kind of thing that will break between versions. With rotatable minimap, the rotatable cameras will be much more usable.
+1

there is a subforum somewhere i think.

Re: Standard camera mode.

Posted: 21 Dec 2009, 23:30
by Argh
Rotating the minimap in Lua means re-implementing a farktonne UI stuff, the kind of thing that will break between versions. With rotatable minimap, the rotatable cameras will be much more usable.
Not really. You can just screen-cap it, store it a texture, put it on a quad, rotate it. Which is pretty much all you'd want to do in the engine to flip it.

It'd be better to open the engine up more, so that it's easier to implement a custom minimap, imo.

Re: Standard camera mode.

Posted: 22 Dec 2009, 11:36
by Regret
Argh wrote:Not really. You can just screen-cap it, store it a texture, put it on a quad, rotate it. Which is pretty much all you'd want to do in the engine to flip it.

It'd be better to open the engine up more, so that it's easier to implement a custom minimap, imo.
Easier said than done, it's quite hard to remake the engine minimap in lua in current Spring.

Re: Standard camera mode.

Posted: 22 Dec 2009, 12:10
by Argh
What's the problem? When DrawInMiniMap() operates, the minimap's already drawn.

Get the relative position of that, and capture that portion of the framebuffer in a bitmap (to see how to create a bitmap in Spring, read the P.O.P.S. source, it's really easy). By definition, it won't capture the quad you drew last DrawInMiniMap(), if you do the capture operation first, because it hasn't been drawn yet.

Then put that bitmap on a TexRect, rotate it 90 degrees, and voila. Perfect rotation. Now, will all the icons be "right side up"? No. But it will work, and it's pretty easy.

Meh, wish I wasn't so busy atm, this really is pretty straightforward OpenGL. Doing something more complicated... not so much. Google "how to capture screen OpenGL".

Re: Standard camera mode.

Posted: 22 Dec 2009, 12:21
by Regret
Argh wrote:What's the problem? When DrawInMiniMap() operates, the minimap's already drawn.

Get the relative position of that, and capture that portion of the framebuffer in a bitmap (to see how to create a bitmap in Spring, read the P.O.P.S. source, it's really easy). By definition, it won't capture the quad you drew last DrawInMiniMap(), if you do the capture operation first, because it hasn't been drawn yet.

Then put that bitmap on a TexRect, rotate it 90 degrees, and voila. Perfect rotation. Now, will all the icons be "right side up"? No. But it will work, and it's pretty easy.
And then recreate unit selection through minimap, giving orders etc.

How would you do that?

Re: Standard camera mode.

Posted: 22 Dec 2009, 13:04
by Argh
Offset the orders / attempts. If you rotate it... X becomes Y, or negative X / negative Y, if an order's passed and mouse is within the bounds of the minimap.

Re: Standard camera mode.

Posted: 22 Dec 2009, 13:36
by Regret
Argh wrote:Offset the orders / attempts. If you rotate it... X becomes Y, or negative X / negative Y, if an order's passed and mouse is within the bounds of the minimap.
What about custom formation widget drawing order lines on minimap?