[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #47506] rgb2ind creates colormap incompartible
From: |
Daniel Roeske |
Subject: |
[Octave-bug-tracker] [bug #47506] rgb2ind creates colormap incompartible to ind2rgb |
Date: |
Wed, 23 Mar 2016 08:33:46 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.87 Safari/537.36 |
URL:
<http://savannah.gnu.org/bugs/?47506>
Summary: rgb2ind creates colormap incompartible to ind2rgb
Project: GNU Octave
Submitted by: dmjr
Submitted on: Mi 23 Mär 2016 08:33:45 GMT
Category: Libraries
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Crash
Status: None
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: 4.0.0
Operating System: GNU/Linux
_______________________________________________________
Details:
When running the following code, which converts rgb to ind and back to rgb,
the following exception is raised:
Mrgb=ind2rgb(Mind,map)
error: ind2rgb: MAP must be a valid colormap
error: called from
ind2x at line 37 column 5
ind2rgb at line 49 column 10
Example code
M(:,:,1) = [225 230 250 243 20 3 244 247 255 255
242 252 239 0 239 224 27 252 255 255
224 239 28 243 236 231 240 11 255 255
243 252 15 224 15 12 251 0 255 255
224 11 252 227 0 11 232 251 0 255
243 4 255 228 19 4 243 224 0 255
0 255 236 251 228 251 224 243 255 0
19 236 255 224 27 12 251 236 255 0
0 255 255 255 255 255 255 255 255 0
255 0 0 0 0 0 0 0 0 255];
M(:,:,2) =[255 255 255 255 0 0 255 255 255 255
255 255 255 0 255 255 0 255 255 255
255 255 0 255 255 255 255 0 255 255
255 255 0 255 0 0 255 0 255 255
255 0 255 255 0 0 255 255 0 255
255 0 255 255 0 0 255 255 0 255
0 255 255 255 255 255 255 255 255 0
0 255 255 255 0 0 255 255 255 0
0 255 255 255 255 255 255 255 255 0
255 0 0 0 0 0 0 0 0 255];
M(:,:,3) = [255 255 255 255 0 0 255 255 255 255
255 255 255 0 0 0 0 255 255 255
255 255 0 0 0 0 0 0 255 255
255 255 0 0 0 0 0 0 255 255
255 0 0 0 0 0 0 0 0 255
255 0 0 0 0 0 0 0 0 255
0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0
255 0 0 0 0 0 0 0 0 255];
[Mind map]=rgb2ind(M)
Mrgb=ind2rgb(Mind,map)
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?47506>
_______________________________________________
Nachricht gesendet von/durch Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #47506] rgb2ind creates colormap incompartible to ind2rgb,
Daniel Roeske <=