3

Currently, I display a .dcm file using XTK in a Renderer2D. Is it possible to change the color of some pixels in this renderer ?

Thank you in advance :)

user2363392
  • 95
  • 1
  • 7

1 Answers1

0

I think you will have be to a lot more specific than this. Generally if you want to change the pixels of the actual Canvas element (that the X.renderer2D draws onto) you have to rewrite the X.renderer2D class - at least according to my experience). But it does depend on what you want to do specifically...

David Basalla
  • 2,996
  • 3
  • 18
  • 22
  • Thanks for your answer :) Actually, I want to change the color of the pixels according to their value in a DICOM File. I already have the value of the pixels but I don't find how to change the color of only some pixels :/ – user2363392 Sep 22 '14 at 08:23
  • 1
    Hmm have you tried using colortables, as they use in some of the XTK tutorials? Other than that, you'd probably have to start editing the X.renderer2D class yourself and change the pixel values in the render() function, as I don't think the API allows for low-level pixel control. – David Basalla Sep 22 '14 at 12:39
  • Yes, I looked at this, and the volume needs to be splitted up. But, my application is generic, it must work with all .dcm files. Thanks for your help :) – user2363392 Sep 22 '14 at 13:01