| Previous | Next |
| D2DERR_ORIGINAL_TARGET_NOT_BOUND | D2DERR_BITMAP_BOUND_AS_TARGET |
D2DERR_INVALID_TARGET
D2DERR_INVALID_TARGET means that code tried to set an image as the Direct2D target even though it is not eligible. Effects cannot be targets, and bitmaps must have the D2D1_BITMAP_OPTIONS_TARGET option to be bound as a target.
What to check
- Check whether the image is an effect output rather than a target-capable bitmap.
- Create the bitmap with the target option when it must receive drawing.
- Use a separate target bitmap and pass it into the effect graph as an input or output as appropriate.
Do not convert the HRESULT into a retry loop; the target selection must be corrected.
Microsoft: Direct2D error codes
Looking for a different code? Search another status or error code.
