Re: [QGIS-Developer] GSoC QGIS 3D Improvement: Week 11 Report

2019-08-15 Thread Ismail Sunni
Hi Nyall,

Thanks for your suggestions. I followed the code that you pointed out. It's
in this commit
https://github.com/ismailsunni/QGIS/commit/2a4caa41e23edfe183055863cee84de60e7b71b9

Unfortunately, it doesn't fix the problem. It still behaves exactly like
the previous approach. Perhaps I missed something?

Best regards.

On Thu, Aug 15, 2019 at 1:19 AM Nyall Dawson  wrote:

> On Thu, 15 Aug 2019 at 03:56, Ismail Sunni  wrote:
>
> > The billboard changes IF the previous billboard is not a symbol. But IF
> the previous billboard is a symbol, and I changed the symbol's properties
> (e.g. color, rotation, shape) the billboard stays the same.
> >
> > In my latest code (pushed by now), I set the billboard to use an
> external image (the success-kid.png) if the symbol's color is white (for
> debugging purpose).
> >
> > If I set the symbol to white, the billboard uses the success-kid as the
> billboard (no matter what is the previous billboard as expected).
> > If the previous symbol is the success-kid, then I changed the symbol's
> properties it will change as expected.
> > If the previous symbol is not the success-kid, then I changed the
> symbol's properties,  it won't change the billboard.
> >
> > When I close QGIS and reopen it, the billboard will show as expected.
> So, I think it's not an issue in saving and restoring the symbol.
>
> Looking over your branch, I'm almost certain it is.
>
> Try using QgsSymbolLayerUtils::symbolProperties to save to symbol to a
> string (see
> https://github.com/qgis/QGIS/blob/master/src/core/callouts/qgscallout.cpp#L237
> )
>
> and something like
>
> https://github.com/qgis/QGIS/blob/master/src/core/callouts/qgscallout.cpp#L261
> to restore.
>
> Nyall
>


-- 
Ismail Sunni
ismailsunni.wordpress.com
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] GSoC QGIS 3D Improvement: Week 11 Report

2019-08-14 Thread Nyall Dawson
On Thu, 15 Aug 2019 at 03:56, Ismail Sunni  wrote:

> The billboard changes IF the previous billboard is not a symbol. But IF the 
> previous billboard is a symbol, and I changed the symbol's properties (e.g. 
> color, rotation, shape) the billboard stays the same.
>
> In my latest code (pushed by now), I set the billboard to use an external 
> image (the success-kid.png) if the symbol's color is white (for debugging 
> purpose).
>
> If I set the symbol to white, the billboard uses the success-kid as the 
> billboard (no matter what is the previous billboard as expected).
> If the previous symbol is the success-kid, then I changed the symbol's 
> properties it will change as expected.
> If the previous symbol is not the success-kid, then I changed the symbol's 
> properties,  it won't change the billboard.
>
> When I close QGIS and reopen it, the billboard will show as expected. So, I 
> think it's not an issue in saving and restoring the symbol.

Looking over your branch, I'm almost certain it is.

Try using QgsSymbolLayerUtils::symbolProperties to save to symbol to a
string (see 
https://github.com/qgis/QGIS/blob/master/src/core/callouts/qgscallout.cpp#L237
)

and something like
https://github.com/qgis/QGIS/blob/master/src/core/callouts/qgscallout.cpp#L261
to restore.

Nyall
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] GSoC QGIS 3D Improvement: Week 11 Report

2019-08-14 Thread Ismail Sunni
Hi Nyall,

Thanks for the reply!

More and more your work is revealing that we'll eventually need to
> tackle this issue head on, and implement proper opacity support in the
> 3d renderer. Everything else is going to be just a hack which won't
> work in all circumstances. I'd suggest not spending much more time on
> this issue given this (current) inherent limitation.


Sure.

I looked over your branch, and it seems the issue is in saving and
> restoring the symbol, not the retrieval of the symbol from the button.
> Is that correct?


The billboard changes IF the previous billboard is not a symbol. But IF the
previous billboard is a symbol, and I changed the symbol's properties (e.g.
color, rotation, shape) the billboard stays the same.

In my latest code (pushed by now), I set the billboard to use an external
image (the success-kid.png) if the symbol's color is white (for debugging
purpose).

If I set the symbol to white, the billboard uses the success-kid as the
billboard (no matter what is the previous billboard as expected).
If the previous symbol is the* success-kid, *then I changed the symbol's
properties it will change as expected.
If the previous symbol is not the *success-kid*, then I changed the
symbol's properties,  it won't change the billboard.

When I close QGIS and reopen it, the billboard will show as expected. So, I
think it's not an issue in saving and restoring the symbol.

Previously, I thought the problem is the changed signal from the button or
the saving and restoring, but it seems it is something else.

Best regards.

On Wed, Aug 14, 2019 at 1:18 AM Nyall Dawson  wrote:

> On Mon, 12 Aug 2019 at 06:54, Ismail Sunni  wrote:
> >
> > Dear QGIS developers,
> >
> > Here is my 11th-week report for my GSoC Project[4]. You can also check
> the project wiki page [2]. Comments and suggestions are welcome :)
> >
> > GSoC QGIS 3D Improvement Week 11 Report
> >
> > Period: 5 August 2019 - 11 August 2019
> >
> > Report
> > 1. What did I complete this week?
> >- Fixing transparency for the billboard to make it smoother on the
> edge. It looks better than the previous result, but still not as smooth as
> I expected
>
> More and more your work is revealing that we'll eventually need to
> tackle this issue head on, and implement proper opacity support in the
> 3d renderer. Everything else is going to be just a hack which won't
> work in all circumstances. I'd suggest not spending much more time on
> this issue given this (current) inherent limitation.
>
> > 2. What am I going to achieve for next week?
> >- Solve using a symbol from QgsSymbolButton
>
> I looked over your branch, and it seems the issue is in saving and
> restoring the symbol, not the retrieval of the symbol from the button.
> Is that correct?
>
> Nyall
>


-- 
Ismail Sunni
ismailsunni.wordpress.com
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] GSoC QGIS 3D Improvement: Week 11 Report

2019-08-13 Thread Nyall Dawson
On Mon, 12 Aug 2019 at 06:54, Ismail Sunni  wrote:
>
> Dear QGIS developers,
>
> Here is my 11th-week report for my GSoC Project[4]. You can also check the 
> project wiki page [2]. Comments and suggestions are welcome :)
>
> GSoC QGIS 3D Improvement Week 11 Report
>
> Period: 5 August 2019 - 11 August 2019
>
> Report
> 1. What did I complete this week?
>- Fixing transparency for the billboard to make it smoother on the edge. 
> It looks better than the previous result, but still not as smooth as I 
> expected

More and more your work is revealing that we'll eventually need to
tackle this issue head on, and implement proper opacity support in the
3d renderer. Everything else is going to be just a hack which won't
work in all circumstances. I'd suggest not spending much more time on
this issue given this (current) inherent limitation.

> 2. What am I going to achieve for next week?
>- Solve using a symbol from QgsSymbolButton

I looked over your branch, and it seems the issue is in saving and
restoring the symbol, not the retrieval of the symbol from the button.
Is that correct?

Nyall
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer