Bug 422525

Summary: 'New From Visible' creates an animated layer if the document has an animated layer
Product: [Applications] krita Reporter: Ahab Greybeard <ahab.greybeard>
Component: Layer StackAssignee: Dmitry Kazakov <dimula73>
Status: RESOLVED FIXED    
Severity: normal CC: dimula73, tamtamy.tymona
Priority: NOR    
Version: nightly build (please specify the git hash!)   
Target Milestone: ---   
Platform: Debian stable   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Screenshot of new-from-visible layer
New-From-Visible .kra file for examination/investigation

Description Ahab Greybeard 2020-06-06 10:05:42 UTC
Created attachment 129099 [details]
Screenshot of new-from-visible layer

SUMMARY
This happens with all appimage versions from 4.2.9 to the 05 June 5.0.0-prealpha (git 9d7f912)

If a document has an animated layer or layers, then a New From Visible operation creates a new layer that is animated.
The new animated layer has the correct 'visible' content as a keyframe at every location where the other animated layers have keyframes (like a logical OR of all other animated layers).

This happens even if the other animated layers have their visibility turned off and/or are not shown in the Timeline.

An illustrative screenshot .png is atached and a .kra file is attached for convenience of further investigation.


STEPS TO REPRODUCE
See Summary and the attached 'New-From-Visible' screenshot

OBSERVED RESULT
See Summary and the attached 'New-From-Visible' screenshot

EXPECTED RESULT
The New-From-Visible layer should not be an animated layer.

SOFTWARE/OS VERSIONS
Krita

 Version: 4.3.0-beta2
 Languages: en_GB, en, en, en_GB, en
 Hidpi: false

Qt

  Version (compiled): 5.12.8
  Version (loaded): 5.12.8

OS Information

  Build ABI: x86_64-little_endian-lp64
  Build CPU: x86_64
  CPU: x86_64
  Kernel Type: linux
  Kernel Version: 4.19.0-9-amd64
  Pretty Productname: Debian GNU/Linux 10 (buster)
  Product Type: debian
  Product Version: 10
  Desktop: MATE

OpenGL Info
 
  Vendor:  "NVIDIA Corporation" 
  Renderer:  "GeForce GTX 750 Ti/PCIe/SSE2" 
  Version:  "4.6.0 NVIDIA 440.82" 
  Shading language:  "4.60 NVIDIA" 
  Requested format:  QSurfaceFormat(version 3.0, options QFlags<QSurfaceFormat::FormatOption>(DeprecatedFunctions), depthBufferSize 24, redBufferSize 8, greenBufferSize 8, blueBufferSize 8, alphaBufferSize 8, stencilBufferSize 8, samples -1, swapBehavior QSurfaceFormat::DoubleBuffer, swapInterval 0, colorSpace QSurfaceFormat::DefaultColorSpace, profile  QSurfaceFormat::CompatibilityProfile) 
  Current format:    QSurfaceFormat(version 4.6, options QFlags<QSurfaceFormat::FormatOption>(DeprecatedFunctions), depthBufferSize 24, redBufferSize 8, greenBufferSize 8, blueBufferSize 8, alphaBufferSize 8, stencilBufferSize 8, samples -1, swapBehavior QSurfaceFormat::DoubleBuffer, swapInterval 0, colorSpace QSurfaceFormat::DefaultColorSpace, profile  QSurfaceFormat::CompatibilityProfile) 
     Version: 4.6
     Supports deprecated functions true 
     is OpenGL ES: false 

QPA OpenGL Detection Info 
  supportsDesktopGL: true 
  supportsOpenGLES: true 
  isQtPreferOpenGLES: false 

Hardware Information

  GPU Acceleration: auto
  Memory: 16039 Mb
  Number of Cores: 8
  Swap Location: /tmp

Current Settings

  Current Swap Location: /tmp
  Current Swap Location writable: true
  Undo Enabled: true
  Undo Stack Limit: 18
  Use OpenGL: true
  Use OpenGL Texture Buffer: true
  Use AMD Vectorization Workaround: false
  Canvas State: OPENGL_SUCCESS
  Autosave Interval: 60
  Use Backup Files: true
  Number of Backups Kept: 1
  Backup File Suffix: ~
  Backup Location: Same Folder as the File
  Backup Location writable: false
  Use Win8 Pointer Input: false
  Use RightMiddleTabletButton Workaround: false
  Levels of Detail Enabled: false
  Use Zip64: false


Display Information
Number of screens: 2
	Screen: 0
		Name: DVI-D-1
		Depth: 24
		Scale: 1
		Resolution in pixels: 1280x1024
		Manufacturer: Dell Inc.
		Model: DELL 1704FPV-
		Refresh Rate: 60
	Screen: 1
		Name: DVI-D-0
		Depth: 24
		Scale: 1
		Resolution in pixels: 1280x1024
		Manufacturer: Dell Inc.
		Model: DELL 1704FPV-
		Refresh Rate: 75


ADDITIONAL INFORMATION
Comment 1 Ahab Greybeard 2020-06-06 10:06:48 UTC
Created attachment 129100 [details]
New-From-Visible .kra file for examination/investigation
Comment 2 Dmitry Kazakov 2020-08-13 13:07:06 UTC
Git commit ccc09d47a84138fcabb579c9e833ff0a132fe2d3 by Dmitry Kazakov.
Committed on 13/08/2020 at 13:06.
Pushed by dkazakov into branch 'krita/4.3'.

Fix extra frames not being added for hidden animation layers

M  +2    -0    libs/image/kis_layer_utils.cpp

https://invent.kde.org/graphics/krita/commit/ccc09d47a84138fcabb579c9e833ff0a132fe2d3
Comment 3 Dmitry Kazakov 2020-08-13 13:07:19 UTC
Git commit 3b197d8e4706d6b9cd5aea90de1f9bc2a1c37e24 by Dmitry Kazakov.
Committed on 13/08/2020 at 13:07.
Pushed by dkazakov into branch 'master'.

Fix extra frames not being added for hidden animation layers

M  +2    -0    libs/image/kis_layer_utils.cpp

https://invent.kde.org/graphics/krita/commit/3b197d8e4706d6b9cd5aea90de1f9bc2a1c37e24