Bug report #15243
photos not displaying in feature form when edit widget width and height set to 0
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | - | ||
Category: | Edit widget | ||
Affected QGIS version: | 2.14.3 | Regression?: | No |
Operating System: | Easy fix?: | No | |
Pull Request or Patch supplied: | No | Resolution: | invalid |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 23179 |
Description
I have a point file with full paths to photos in the attribute table.
I set the edit widget to "photo" and left the height and width to 0.
It says leaving at 0 the feature form will generate a preview based on an optimal size.
When identifying those points on the map and viewing them in feature form mode, no preview is generated at all.
It looks like the optimal size is 1px X 1px. I can see a tiny dot up there (picture attached).
If I open the attribute table and "switch to form view" there is a small strip at the top that looks like the image.
But it's only 1 or 2 pixels in height, the width covers the entire width (picture attached).
I'm not sure if the category for this should be "Edit widget" or "Forms" so I've picked edit widget for now.
History
#1 Updated by Donovan Cameron over 8 years ago
FYI, this is on Windows 8.1 and QGIS is installed via the OSGeo4W installer.
#2 Updated by Nyall Dawson over 8 years ago
- Status changed from Open to Feedback
Please test on 2.16 or 2.14.4. there's been related changes which may have fixed this.
#3 Updated by Donovan Cameron over 8 years ago
- File small_photos_qgis_attribute_table_formview.png added
- File working_photos_qgis_attribute_table_formview.png added
Trying on QGIS 2.16,
Interesting... I populated an excel spreadsheet manually with full path to photos, lat, lon, and some other attributes. Converted that to a CSV then generated points using the Add Delimited Text layer.
This layer works perfectly when setting the photo widget to auto in both the identify feature and attribute table form views. Awesome!
But maybe as a separate issue, the original layer that I was having troubles with still shows a single pixel in the form view when using the identify tool (picture attached) and in the attribute table form view shows a very small picture that's hard to see (also attached picture). At least in the attribute table it shows something =)
Note that this troublesome point layer was generated differently, using the "Geotag and import photos" plugin and its "Import photos" tool. So that might be related and may have to be addressed with the plugin maintainers.
But I can't figure out why it has trouble resizing or showing a full picture, because it still has a fullpath string field to the photos that are the same resolution and sourced from the same field device used to capture them in the first place. Same as the working layer using the excel -> csv -> points layer method.
If you'd like, I can provide the two separate layers and batch of photos off list because I can't distribute them in a public forum, for testing.
#4 Updated by Nyall Dawson over 8 years ago
I think the difference is that the layer with the smaller photos has many more fields - so the auto size is making the photos smaller in order to leave more room for the other fields.
#5 Updated by Donovan Cameron over 8 years ago
Right on, that was it.
Deleting a bunch of fields makes it work a lot better. Some datasets I have do need lots of fields and I think other users may experience the same behaviour I'm seeing.
#6 Updated by Nyall Dawson over 8 years ago
- Resolution set to invalid
- Status changed from Feedback to Closed